Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to set up mod_mime for javascript. My webserver returns this content-type for js files:

Content-Type:application/x-javascript; charset=utf-8

so obviously the directive

ExpiresByType application/x-javascript "access plus 1 year"

specified in .htaccess doesn't work.

So, any ideas how to specify mime type in such case?

PS: the same (adding of ; charset=utf-8) happens also with .css, but all the binary types (images) work fine.

share|improve this question
Sorry, but what mime-type are you trying to change it to? What is your problem with it report utf-8? – Zoredache Feb 20 '12 at 10:29
@Zoredache: I don't want to change - I want to set up the cache expiration date for jss and css and don't know how to specify mime-type for them. – zerkms Feb 20 '12 at 19:54

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.