do_action( 'pre_post_update', int $post_id, array $data )

Fires immediately before an existing post is updated in the database.


$post_id int
Post ID.
$data array
Array of unslashed post data.

Top ↑

More Information

The hook is called just before $wpdb::update(), only on updates (not creates).

This might be useful for editing the contents of $wpdb->posts before the content is updated to the DB.

Top ↑


File: wp-includes/post.php. View all references

do_action( 'pre_post_update', $post_id, $data );

Top ↑


Version Description
2.5.0 Introduced.

Top ↑

User Contributed Notes

You must log in before being able to contribute a note or feedback.