Hi!
I've got some PHP-scripts outputting Javascript code, and they are downloaded and used as javascript files in the eyes of the browser.
By using content-type in a header directive of the php-file litespeed correctly gzips the file the way I want.
<? header ('Content-Type: application/x-javascript'); ?>
The problem is that litespeed always appends these headers for files ending with '.php'
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
That makes the browsers reload the file every time and it is rather large.
How do I go about making litespeed + PHP output the cache parameters of content-type application/x-javascript instead of for php?
I've got some PHP-scripts outputting Javascript code, and they are downloaded and used as javascript files in the eyes of the browser.
By using content-type in a header directive of the php-file litespeed correctly gzips the file the way I want.
<? header ('Content-Type: application/x-javascript'); ?>
The problem is that litespeed always appends these headers for files ending with '.php'
Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
Pragma: no-cache
That makes the browsers reload the file every time and it is rather large.
How do I go about making litespeed + PHP output the cache parameters of content-type application/x-javascript instead of for php?