[wp-hackers] wp_enqueue_script() and URLs with 2+ parameters
Matt Martz
mdmartz at sivel.net
Fri Feb 27 20:01:34 GMT 2009
On Fri, Feb 27, 2009 at 2:50 PM, Glenn Ansley <glenn at glennansley.com> wrote:
>>wp_enqueue_script('my-custom-js',"$template_url/ js/ my-custom-js .js.php?p1=A&p2=B&p3=C",array('jquery'),'1.0');
>
> Oh yeah... depending on where these query vars are coming from, it
> might be wise to add some form of cleaning back to them in your filter
> since you're now bypassing clean_url()
>
> Glenn Ansley
> WordPress Pluign Development
> http://fullthrottledevelopment.com
>
> On Fri, Feb 27, 2009 at 2:44 PM, Austin Matzko <if.website at gmail.com> wrote:
>> On Fri, Feb 27, 2009 at 1:41 PM, Glenn Ansley <glenn at glennansley.com> wrote:
>>>>To fix this in current WordPress, filter 'script_loader_src'
>>> I believe this is too early. Whatever you output from
>>> script_loader_src will still be cleaned by clean_url(). Correct? (i'm
>>> not testing as i respond)
>>
>> You are correct. My mistake.
>> _______________________________________________
>> wp-hackers mailing list
>> wp-hackers at lists.automattic.com
>> http://lists.automattic.com/mailman/listinfo/wp-hackers
>>
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
>
So I'm not sure I understand what the problem with having the &
replaced with & is.
The reason it is done is because & signs on their own do not validate
as XHTML. I don't see any reason why having & wouldn't work.
Generally & signs are replaced with & but & is the same
thing.
--
Matt Martz
matt at sivel.net
More information about the wp-hackers
mailing list