Created
October 1, 2014 22:34
-
-
Save jeffikus/3fa2f751515af3360316 to your computer and use it in GitHub Desktop.
WPDB Update
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// table, $data, $where, $format, $where_format | |
$wpdb->update( | |
$wpdb->postmeta, | |
array( | |
'meta_value' => 'false' | |
), | |
array( | |
'post_id' => 5, | |
'meta_key' => '_custom_meta_key', | |
), | |
array( | |
'%s' | |
), | |
array( | |
'%d', | |
'%s' | |
) | |
); | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment