This makes no sense, but in looking at my view source across browsers, wp_localize_script()
is inserting tags as expected for all browsers other than IE7,8,9. The script tag is simply not there in those browsers. I have it bound to "jquery", since I want to make sure it's included no matter what (rather than binding it to any specific user-defined script). It's being called in my theme's functions.php file.
The documentation for wp_localize_script seems to suggest that the script must be registered before calling this function. Given that the function is always being called at the same place, it seems that perhaps jQuery is being enqueued or registered at different times depending on browser? That seems very odd indeed, as WordPress doesn't natively do a lot of browser detection out of the box.
I can get wp_localize_script working if I bind it to one of my custom enqueued scripts and make sure the function call is immediately after that script is enqueued. This is why I suspect it has something to do with the queueing order of jQuery.
Can anyone suggest what might be going on here?