How do you update a custom table using wp functions
-
This kind of works, my variables get wiped in the DB though, not updated. Please help!
global $wpdb; if( !function_exists('get_option') ) { require_once('wp-config.php'); }
$wpdb->update("mytable", array('mycol1' => $_REQUEST["v1"], 'mycol2' => $_REQUEST["v2"], 'mycol3' => $_REQUEST["v3"] ), array('qsId' => $_REQUEST["customer_id"] ));
So is the second array where I specify the ID of the table row to update?
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘How do you update a custom table using wp functions’ is closed to new replies.