From afc4ec89bd034bd091c65a8f8545e4a254513a17 Mon Sep 17 00:00:00 2001 From: ryan Date: Fri, 19 May 2006 17:22:19 +0000 Subject: [PATCH] Add publish_page hook git-svn-id: http://svn.automattic.com/wordpress/trunk@3787 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/functions-post.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/wp-includes/functions-post.php b/wp-includes/functions-post.php index e56dec42b..ef83fbbea 100644 --- a/wp-includes/functions-post.php +++ b/wp-includes/functions-post.php @@ -208,6 +208,9 @@ function wp_insert_post($postarr = array()) { if ( !empty($page_template) ) if ( ! update_post_meta($post_ID, '_wp_page_template', $page_template)) add_post_meta($post_ID, '_wp_page_template', $page_template, true); + + if ( $post_status == 'publish' ) + do_action('publish_page', $post_ID); } if ( 'future' == $post_status ) {