[wp-trac] [WordPress Trac] #27888: Feature request: `get_current_admin_url()` and `get_current_admin_hook()`

WordPress Trac noreply at wordpress.org
Thu Mar 3 10:53:58 UTC 2016


#27888: Feature request: `get_current_admin_url()` and `get_current_admin_hook()`
-------------------------------------------------+-------------------------
 Reporter:  Denis-de-Bernardy                    |       Owner:
     Type:  feature request                      |      Status:  new
 Priority:  normal                               |   Milestone:  Awaiting
Component:  Administration                       |  Review
 Severity:  normal                               |     Version:  3.9
 Keywords:  needs-patch needs-unit-tests good-   |  Resolution:
  first-bug                                      |     Focuses:
                                                 |  administration
-------------------------------------------------+-------------------------

Comment (by swissspidy):

 Replying to [comment:6 mrahmadawais]:
 > Replying to [comment:3 swissspidy]:
 >
 > I am up for it. Could you tell me where would it go? Inside
 `pluggable.php` ?

 `pluggable.php` is only for "pluggable" functions (wrapped in `if ( !
 function_exists( ... ) )` blocks), which is considered a bad practice.

 I'm not that familiar with the file structure inside `wp-admin`, but I'd
 put it inside `wp-admin/includes/misc.php` for now.

 Note: Not `wp-includes`, because the suggested functions are only needed
 in the admin.

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


More information about the wp-trac mailing list