WordPress Hooks Explorer

Listing all hooks extracted WordPress Core


Details about save_post_

Back to home

Files

Filename Hook Type Line Number PHP Doc
wp-includes/post.php do_action 4706 /**
* Fires once a post has been saved.
*
* The dynamic portion of the hook name, `$post->post_type`, refers to
* the post type slug.
*
* Possible hook names include:
*
* - `save_post_post`
* - `save_post_page`
*
* @since 3.7.0
*
* @param int $post_ID Post ID.
* @param WP_Post $post Post object.
* @param bool $update Whether this is an existing post being updated.
*/
wp-includes/post.php do_action 4888 /**
* Publishes a post by transitioning the post status.
*
* @since 2.1.0
*
* @global wpdb $wpdb WordPress database abstraction object.
*
* @param int|WP_Post $post Post ID or post object.
*/
wp-includes/class-wp-customize-manager.php do_action 3105 /**
* Trashes or deletes a changeset post.
*
* The following re-formulates the logic from `wp_trash_post()` as done in
* `wp_publish_post()`. The reason for bypassing `wp_trash_post()` is that it
* will mutate the the `post_content` and the `post_name` when they should be
* untouched.
*
* @since 4.9.0
*
* @see wp_trash_post()
* @global wpdb $wpdb WordPress database abstraction object.
*
* @param int|WP_Post $post The changeset post.
* @return mixed A WP_Post object for the trashed post or an empty value on failure.
*/

Hook Parameters

Parameter Type Name Description
int $post_ID Post ID.
WP_Post $post Post object.
bool $update Whether this is an existing post being updated.
int $post_ID Post ID.
WP_Post $post Post object.
bool $update Whether this is an existing post being updated.