[wp-trac] [WordPress Trac] #27056: Add hook for custom post.php actions

WordPress Trac noreply at wordpress.org
Sun Dec 6 17:58:23 UTC 2015


#27056: Add hook for custom post.php actions
-------------------------------------------------+-------------------------
 Reporter:  jfarthing84                          |       Owner:
     Type:  enhancement                          |      Status:  new
 Priority:  normal                               |   Milestone:  Future
Component:  Posts, Post Types                    |  Release
 Severity:  normal                               |     Version:
 Keywords:  good-first-bug needs-docs has-patch  |  Resolution:
                                                 |     Focuses:
-------------------------------------------------+-------------------------
Changes (by brianvan):

 * keywords:  good-first-bug needs-docs needs-patch => good-first-bug needs-
     docs has-patch


Comment:

 This is how I tested the patch I submitted:
 Used a clean copy of WP (code, database) & tested the patch + the below
 action hook to successfully trigger the new action using
 the site url + '''/wp-admin/post.php?post=1&action=asdflkjadsflkjasdf'''
 (on clean installs this is the edit screen for the "Hello World" post)

 The result was a page with just the words "Theme test", as expected.

 {{{#!php
 <?php
 function second_theme_test(){
         echo "Theme test";
         die();
 }
 add_action( 'post_action_asdflkjadsflkjasdf' , "second_theme_test" );

 }}}

--
Ticket URL: <https://core.trac.wordpress.org/ticket/27056#comment:6>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list