MDL-52835 mod_data: Correct MIME type for JS template

This commit is contained in:
Michael de Raadt 2016-01-20 11:40:39 +11:00
parent eddec36d49
commit acc9fed2ee

View File

@ -38,7 +38,7 @@ if ($data = $DB->get_record('data', array('id'=>$d))) {
header('Expires: ' . gmdate("D, d M Y H:i:s", time() + $lifetime) . ' GMT');
header('Cache-control: max_age = '. $lifetime);
header('Pragma: ');
header('Content-type: text/css; charset=utf-8'); // Correct MIME type
header('Content-type: application/javascript; charset=utf-8'); // Correct MIME type.
echo $data->jstemplate;
}