[wp-trac] [WordPress Trac] #13265: Filter results of get_page_templates()

WordPress Trac wp-trac at lists.automattic.com
Mon Apr 11 08:46:56 UTC 2011


#13265: Filter results of get_page_templates()
-------------------------+-----------------------------
 Reporter:  nathanrice   |       Owner:  nathanrice
     Type:  enhancement  |      Status:  new
 Priority:  normal       |   Milestone:  Future Release
Component:  Themes       |     Version:  3.0
 Severity:  normal       |  Resolution:
 Keywords:  has-patch    |
-------------------------+-----------------------------

Comment (by nacin):

 This won't be enough to make this work. You'd also have to filter
 get_page_template() (via the {$type}_template filter in
 get_query_template(), with $type being 'page'), because the
 validate_file() check in get_page_template() will fail.

 Selecting a special template doesn't help much when the template loader
 can't do anything with it.

 In order to back a patch like this, it would be great seeing a plugin
 uploaded here that then implements something using it. That way we know
 we're doing it correctly. If that happens soon this is something that can
 make it into trunk after some review.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/13265#comment:14>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list