W3cubDocs

/WordPress

do_action( 'wp_insert_post', int $post_ID, WP_Post $post, bool $update )

Fires once a post has been saved.

Description

Parameters

$post_ID

(int) Post ID.

$post

(WP_Post) Post object.

$update

(bool) Whether this is an existing post being updated or not.

Source

File: wp-includes/post.php

View on Trac

Changelog

Version Description
2.0.0 Introduced.

© 2003–2019 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/hooks/wp_insert_post