[wp-trac] [WordPress Trac] #16408: get_bloginfo('template_url') is not returning valid URLs.

WordPress Trac wp-trac at lists.automattic.com
Sun Jan 30 08:04:50 UTC 2011


#16408: get_bloginfo('template_url') is not returning valid URLs.
--------------------------+-------------------------------------
 Reporter:  figaroo       |      Owner:
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  General       |    Version:  3.0.3
 Severity:  normal        |   Keywords:  spaces url template_url
--------------------------+-------------------------------------
 There seems to be a general consensus on the #wordpress IRC channel that
 URLs cannot contain spaces. I agree with this, and I'm almost sure the
 entire internet community would to. Based on this axiom,
 get_bloginfo('template_url') should return URLs with spaces properly
 encoded, otherwise, it's not returning a valid URL, hence it's not
 returning a URL at all. I'm guessing that get_bloginfo('template_url') is
 suppose to return a URL, so this must mean that it's not currently (as of
 version 3.0.3) doing what it's suppose to.

 As for what a properly encoded space character in a URL would be, I'm not
 exactly sure. I know it's either %20 or +, but I wont make the decision as
 to which of these it is.

 If you by any chance believe that URLs *should* contain spaces, then
 that's another problem related to wp_enqueue_script. wp_enqueue_script
 removes spaces from it's URL. Again, if you think URLs should contain
 spaces, then wp_enqueue_script should include them.

 Either way you think about it, get_bloginfo (including bloginfo) or
 wp_enqueue_script contains a defect. You may argue that you should not use
 spaces in your directory/file names to begin with, but this argument is
 irrelevant.

 Thank you. I would appreciate this issue not being overlooked. :)

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


More information about the wp-trac mailing list