[wp-trac] [WordPress Trac] #12958: locate_template restricts the use of get_generic_template

WordPress Trac wp-trac at lists.automattic.com
Sat Apr 10 16:59:58 UTC 2010


#12958: locate_template restricts the use of get_generic_template
-----------------------------+----------------------------------------------
 Reporter:  w3prodigy        |       Owner:            
     Type:  feature request  |      Status:  new       
 Priority:  normal           |   Milestone:  Unassigned
Component:  General          |     Version:            
 Severity:  normal           |    Keywords:            
-----------------------------+----------------------------------------------
 The locate_template functions utilizes require_once to include files. With
 get_generic_template providing the ability to simply include template
 files we should make it more flexible so users can include the same file
 twice from one template file.

 For example if I wanted to create a custom template for a parent page with
 children and display the content from the children on the parent page I
 would use get_generic_template('loop','page') for the loop for the parent
 page, followed by another get_generic_template('loop','page') for each
 child page.

 I suggest we replace the require_once function of locate_template with a
 require function to increase the administrators accessibility to template
 files.

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


More information about the wp-trac mailing list