Passenger no styles being applied but can be downloaded
I installed Redmine on Centos 6 using apache2 and 开发者_开发知识库phusion's passenger.
I can access Redmine fine and all the controls seem to work. The issue is it all appears un-styled.
If I visit the url of the stylesheet verbatim from the rendered html it pulls it up fine. If I embed the styles of the stylesheet directly into the page it renders as it should.
I'm not getting any apache or Redmine errors and I do see requests for the stylesheets in apache's access log.
In firebug on the css tab it shows no styles but has the 'application.css' file as an asset and when I click edit it loads the data just fine.
I cleared my cache as well as asked people around me to try and we all get the same issue. I've tried restarting the server and the Redmine application.
To make it even more odd, IE8 displays correctly. IE9, FF, Safari and Chrome all display the page incorrectly.
Redmine is also the document root, it is not in a subdirectory.
I tested using an ajax request and was able to retrieve the styles ok also. My only assumption at this point is that I don't have Passenger configured correctly and the user agent or headers sent by a browser requesting resources is different and somehow affected? That is the best guess I got.
Any help is very greatly appreciated.
I found the issue. Apache was returning text/plain as the mimetype. Fixed by adding
Addtype text/css .css
To .htaccess
精彩评论