CSS won't load in Firefox

hello, i just set up my first ever rails+nginx+mongrel and it’s looking
sweet!

here’s nginx.conf http://pastie.org/243487

the problem is though, my css file won’t load in firefox. i tried
including include /usr/local/etc/nginx/mime.types; but it didn’t make
a difference…

thanks

is the css being called from the right source or is it being proxied
to mongrels/rails?

you should log the requests / debug too. maybe that will expose where
the request is going.

On Tue, Jul 29, 2008 at 1:30 PM, Redd V. [email protected]
wrote:

hello, i just set up my first ever rails+nginx+mongrel and it’s looking sweet!

here’s nginx.conf http://pastie.org/243487

the problem is though, my css file won’t load in firefox. i tried
including include /usr/local/etc/nginx/mime.types; but it didn’t make
a difference…

Nothing strikes me as incorrect with your config. Are you getting
404s in your logs and/or have you tried enabling error logging to get
a little more info? My hunch is incorrect paths in your markup.

it works just fine in ie. and in firefox when the production
environment is development.

production.log and nginx-error.log shows no signs of an error…

i had the exact same problem with apache a while back, and loading the
mime module fixed it.

sorry, it seemed to be these two lines after all

include /usr/local/etc/nginx/mime.types;

default_type application/octet-stream;

many thanks guys!

On Tue, Jul 29, 2008 at 2:01 PM, Redd V. [email protected]
wrote:

it works just fine in ie. and in firefox when the production
environment is development.

Are you SURE IE isn’t caching an older version of the css file? Are
you dynamically generating your css files and serving them from
mongrel? If so, are you setting the proper headers to serve the css
files w/ the appropriate mime-type? What does curl -vv
http://foo.com/path/to/my.css yield?

production.log and nginx-error.log shows no signs of an error…

What level do you have your access log logging at?

i believe the lack of mime types confused firefox on how to treat a css
file.

it’s all good now though :slight_smile: