On this page
do_action( 'transition_post_status', string $new_status, string $old_status, WP_Post $post )
Fires when a post is transitioned from one status to another.
Parameters
$new_statusstring-
New post status.
$old_statusstring-
Old post status.
$postWP_Post-
Post object.
Source
File: wp-includes/post.php. View all references
do_action( 'transition_post_status', $new_status, $old_status, $post );
Related
Used By
| Used By | Description |
|---|---|
| wp_transition_post_status() wp-includes/post.php | Fires actions related to the transitioning of a post’s status. |
Changelog
| Version | Description |
|---|---|
| 2.3.0 | Introduced. |
© 2003–2022 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/hooks/transition_post_status