[wp-trac] [WordPress Trac] #24834: wp_enqueue_script passing null for $ver produces unexpected results

WordPress Trac noreply at wordpress.org
Mon Aug 5 18:09:06 UTC 2013


#24834: wp_enqueue_script passing null for $ver produces unexpected results
--------------------------+-----------------------
 Reporter:  bobbingwide   |       Owner:
     Type:  defect (bug)  |      Status:  reopened
 Priority:  normal        |   Milestone:
Component:  General       |     Version:  3.5.2
 Severity:  normal        |  Resolution:
 Keywords:  close         |
--------------------------+-----------------------

Comment (by helen):

 What exactly is it you are trying to accomplish here? The handle can be
 anything, so name it `my-example-widget-2.0` and `my-example-widget-2.4`
 or something. It just has special behavior when a query string is
 involved. If you have to generate it programmatically for some reason,
 replacing the ? sounds good, or try a sanitize function like
 `sanitize_key()`.

 Your patch would change current behavior. Note that `$src` can be altered
 before its usage in that conditional.

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


More information about the wp-trac mailing list