[wp-hackers] wp_enqueue_script interCapping gotcha

Art Delano ajd at cloudiness.com
Wed Oct 7 15:25:19 UTC 2009

Ignore the below: It was actually a typo I'd made that prevented  
wp_footer() from loading in theme. And it looks like intercapping is  
now permissible in wp_enqueue_script handles as well.

I had hoped my first post to this list wouldn't involve shooting  
myself in the foot. Sorry, everybody.


On Oct 7, 2009, at 11:17 AM, Art Delano wrote:

> wp_enqueue_script got me again this morning. I couldn't figure out  
> why the following didn't work:
> function jquerykicker() {
>   $asdf = WP_CONTENT_URL.'/themes/mytheme/scripts/display.js';
>   wp_enqueue_script('launchAll',$asdf,array('jquery'),'',TRUE);
> }
> add_action('template_redirect','jquerykicker');
> The problem was "launchAll" - wp_enqueue_script will only accept  
> lowercase strings for the handle. Changing it to  
> "launchall" (without editing the display.js file) fixed everything.
> Is there a reason for this constraint? There's no harm to my scripts  
> to keep the string lowercased, but I feel like it wastes a lot of  
> time to repeatedly debug sites that aren't working because I forgot  
> to lowercase a string.
> Art
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers

More information about the wp-hackers mailing list