header(\"Content-type: text/css\"); works in Firefox, Chrome and other, but not in Internet Explorer 9. I am not sure what\'s up.
In Chrome an
The article Handle Images/CSS/JS as PHP without httpd.conf Using .htaccess helped me figure out the issue.
You basically do all the same stuff as everyone else mentioned (setting header in PHP, etc.), but also use .htaccess to set the AddHandler param.
ForceType application/x-httpd-php
AddHandler application/x-httpd-php .css
This way you can name it with .css and still have PHP parse it.