pre_post_insert action-hookWP 6.9.0

Fires immediately before a new post is inserted in the database.

Usage

add_action( 'pre_post_insert', 'wp_kama_pre_post_insert_action' );

/**
 * Function for `pre_post_insert` action-hook.
 * 
 * @param array $data Array of unslashed post data.
 *
 * @return void
 */
function wp_kama_pre_post_insert_action( $data ){

	// action...
}
$data(array)
Array of unslashed post data.

Changelog

Since 6.9.0 Introduced.

Where the hook is called

wp_insert_post()
pre_post_insert
wp-includes/post.php 4933
do_action( 'pre_post_insert', $data );

Where the hook is used in WordPress

Usage not found.