mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-06-28 22:30:04 +00:00
Minor cleanups.
git-svn-id: https://develop.svn.wordpress.org/trunk@2923 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -70,7 +70,9 @@ function write_post() {
|
||||
// Move child posts to a new parent
|
||||
function relocate_children($old_ID, $new_ID) {
|
||||
global $wpdb;
|
||||
$wpdb->query("UPDATE $wpdb->posts SET post_parent = $new_ID WHERE post_parent = $old_ID");
|
||||
$old_ID = (int) $old_ID;
|
||||
$new_ID = (int) $new_ID;
|
||||
return $wpdb->query("UPDATE $wpdb->posts SET post_parent = $new_ID WHERE post_parent = $old_ID");
|
||||
}
|
||||
|
||||
// Update an existing post with values provided in $_POST.
|
||||
|
||||
Reference in New Issue
Block a user