[wp-trac] [WordPress Trac] #15686: Detect the current page template tag

WordPress Trac wp-trac at lists.automattic.com
Sun Dec 5 13:07:10 UTC 2010


#15686: Detect the current page  template tag
-----------------------------+----------------------------------------------
 Reporter:  numediaweb       |       Owner:                          
     Type:  feature request  |      Status:  new                     
 Priority:  normal           |   Milestone:  Awaiting Review         
Component:  Template         |     Version:  3.1                     
 Severity:  normal           |    Keywords:  get_current_page pagenow
-----------------------------+----------------------------------------------
 It would be of a great use, specially for theme developers, to add a
 get_current_page template tag for Wordpress. A function that detects the
 current page, because now the only solution is to use the core variable
 $pagenow such as:

 {{{
 if ($pagenow == 'wp-login.php' )
 }}}

 as we know; using global core variables is not a good practice, but until
 now there's no other solution.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/15686>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list