[wp-trac] [WordPress Trac] #18298: deprecate TEMPLATEPATH and STYLESHEETPATH

WordPress Trac wp-trac at lists.automattic.com
Wed Nov 16 15:45:52 UTC 2011


#18298: deprecate TEMPLATEPATH and STYLESHEETPATH
---------------------------+------------------------------
 Reporter:  aaroncampbell  |       Owner:
     Type:  enhancement    |      Status:  new
 Priority:  normal         |   Milestone:  Awaiting Review
Component:  Themes         |     Version:  3.0
 Severity:  normal         |  Resolution:
 Keywords:  has-patch      |
---------------------------+------------------------------
Changes (by aaroncampbell):

 * version:   => 3.0


Old description:

> As part of #15806 we wanted to add unit tests, but we came across a
> problem in #UT22.  Basically `locate_template()` uses these constants
> instead of `get_template_directory()` and `get_stylesheet_directory()`
> which makes it impossible to use `switch_theme()`.  It looks like the
> constants are only used in about 20 places through core, so I recommend
> we fix those places and deprecate the constants.

New description:

 As part of #15086 we wanted to add unit tests, but we came across a
 problem in #UT22.  Basically `locate_template()` uses these constants
 instead of `get_template_directory()` and `get_stylesheet_directory()`
 which makes it impossible to use `switch_theme()`.  It looks like the
 constants are only used in about 20 places through core, so I recommend we
 fix those places and deprecate the constants.

--

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


More information about the wp-trac mailing list