Changeset 6238
- Timestamp:
- 10/13/2007 12:54:26 AM (17 years ago)
- Location:
- trunk/wp-includes
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/post.php
r6237 r6238 705 705 706 706 if ($update) { 707 $wpdb-> db_update( $wpdb->posts, $data, 'ID', $post_ID );707 $wpdb->update( $wpdb->posts, $data, 'ID', $post_ID ); 708 708 } else { 709 709 $data['post_mime_type'] = stripslashes( $post_mime_type ); // This isn't in the update 710 $wpdb-> db_insert( $wpdb->posts, $data );710 $wpdb->insert( $wpdb->posts, $data ); 711 711 $post_ID = (int) $wpdb->insert_id; 712 712 } … … 1295 1295 1296 1296 if ($update) { 1297 $wpdb-> db_update($wpdb->posts, $data, 'ID', $post_ID);1298 } else { 1299 $wpdb-> db_insert($wpdb->posts, $data);1297 $wpdb->update($wpdb->posts, $data, 'ID', $post_ID); 1298 } else { 1299 $wpdb->insert($wpdb->posts, $data); 1300 1300 $post_ID = (int) $wpdb->insert_id; 1301 1301 } -
trunk/wp-includes/wp-db.php
r6236 r6238 257 257 * @return mixed results of $this->query() 258 258 */ 259 function db_insert($table, $data) {259 function insert($table, $data) { 260 260 $data = add_magic_quotes($data); 261 261 $fields = array_keys($data); … … 271 271 * @return mixed results of $this->query() 272 272 */ 273 function db_update($table, $data, $where_col, $where_val){273 function update($table, $data, $where_col, $where_val){ 274 274 $data = add_magic_quotes($data); 275 275 $bits = array();
Note: See TracChangeset
for help on using the changeset viewer.