According to this: Javascript MIME Type, it seems that I should be serving my JS as "text/javascript". When I inspect the network communication between my browser and localhost (or my server), the MIME type of the JS that are hosted on my web server is application/x-javascript. The JS from Google CDN (e.g. jQuery) is text/javascript.
I want to make my JS become text/javascript. In my .htaccess, I tried adding this: AddType text/javascript .js, but it didn't change my MIME type.
Suggestions?
application/javascript. No browser cares if it isapplication/x-javascriptthough. The best way to fix that would be to upgrade the underlying system, which has an out of date mime.types file.application/javascriptis the "proper" MIME type, I'm trying to do as Google and usetext/javascript.application/x-javascriptappears on both my WAMP and LAMP system. I'm thinking that somehow my code, .htaccess, etc. is the culprit.