[wp-trac] [WordPress Trac] #14720: get_bloginfo code, with get_template_* and get_stylesheet_*

WordPress Trac wp-trac at lists.automattic.com
Thu Jan 13 17:15:29 UTC 2011


#14720: get_bloginfo code, with get_template_* and get_stylesheet_*
--------------------------+----------------------
 Reporter:  Frumph        |       Owner:
     Type:  defect (bug)  |      Status:  closed
 Priority:  normal        |   Milestone:
Component:  General       |     Version:
 Severity:  normal        |  Resolution:  invalid
 Keywords:  close         |
--------------------------+----------------------
Changes (by nacin):

 * status:  new => closed
 * resolution:   => invalid
 * milestone:  Awaiting Review =>


Old description:

> wp-includes/general-template.php line 436 (WP 3.0.1)
> {{{
>                 case 'stylesheet_url':
>                         $output = get_stylesheet_uri();
>                         break;
>                 case 'stylesheet_directory':
>                         $output = get_stylesheet_directory_uri();
>                         break;
>                 case 'template_directory':
>                 case 'template_url':
>                         $output = get_template_directory_uri();
>                         break;
> }}}
>
> The problem with this is, template_directory and stylesheet_directory
> should be getting the get_template_directory() and
> get_stylesheet_directory() and not the URI portion of it, since the
> difference between the two is major, if someone wants to get the path
> location on the system rather then the URI
>
> I can recognize _url being used to get the URL of course, but the path
> isn't being represented, so in favor of of using the get_bloginfo() i've
> kept using the get_* functions instead.

New description:

 wp-includes/general-template.php line 436 (WP 3.0.1)
 {{{
                 case 'stylesheet_url':
                         $output = get_stylesheet_uri();
                         break;
                 case 'stylesheet_directory':
                         $output = get_stylesheet_directory_uri();
                         break;
                 case 'template_directory':
                 case 'template_url':
                         $output = get_template_directory_uri();
                         break;
 }}}

 The problem with this is, template_directory and stylesheet_directory
 should be getting the get_template_directory() and
 get_stylesheet_directory() and not the URI portion of it, since the
 difference between the two is major, if someone wants to get the path
 location on the system rather then the URI

 I can recognize _url being used to get the URL of course, but the path
 isn't being represented, so in favor of of using the get_bloginfo() i've
 kept using the get_* functions instead.

--

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


More information about the wp-trac mailing list