[wp-trac] [WordPress Trac] #13691: Make get_template_part() accept multiple template names

WordPress Trac wp-trac at lists.automattic.com
Mon Jul 12 10:24:09 UTC 2010

#13691: Make get_template_part() accept multiple template names
 Reporter:  wjm          |       Owner:                
     Type:  enhancement  |      Status:  new           
 Priority:  normal       |   Milestone:  Future Release
Component:  Template     |     Version:                
 Severity:  normal       |    Keywords:  needs-patch   

Comment(by wjm):

 Changes made to the last patch.

 require_once argument added to get_template_part(),
 this is set to true to get_header(), get_footer() and get_sidebar()

 A cache listing the template files has been created, which I hope speeds
 things up avoiding to run file_exists().
 It also reads template subdirectories, only on demand (not commonly used
 buy it was possible to include a template using a / in its slug or name).

 If someone can benchmark this, but all the code was made with speed in

Ticket URL: <http://core.trac.wordpress.org/ticket/13691#comment:8>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software

More information about the wp-trac mailing list