Welcome to WebmasterWorld Guest from 100.26.176.182

Forum Moderators: open

Message Too Old, No Replies

Firefox doesn't render my stylesheets

Firefox doesn't render css on my site, but IE and opera do.

     
3:46 pm on Apr 3, 2007 (gmt 0)

New User

10+ Year Member

joined:Apr 3, 2007
posts:3
votes: 0


Hi, I was wondering if anyone could give me some pointers to why my site isn't being rendered properly in Firefox; it's a WordPress blog. Everything is styled correctly(ish) in IE and Opera... It's like Firefox is completely ignoring the stylesheet.

I don't understand a lot about doctypes and whatnot, but if I remove the Doctype decleration then Firefox *will* render it ok (any doctype, XHTML / HTML seems to break it). The page is mostly derived from a hacked theme, so I haven't written it all myself. There are a few validation errors due to unclosed paragraphs, no /> on img tags, etc, I'll try and fix these when I can access the root files... Is this really all that's causing the problem?

Thanks for any help,
- Matt

<Sorry, no personal links.
See Forum Charter [webmasterworld.com]>

[edited by: tedster at 4:07 pm (utc) on April 3, 2007]

4:09 pm on Apr 3, 2007 (gmt 0)

Senior Member

WebmasterWorld Senior Member tedster is a WebmasterWorld Top Contributor of All Time 10+ Year Member

joined:May 26, 2000
posts:37301
votes: 0


The first thing I suspect is an incorrect MIME type on the server for .css files. It should be text/css and not text/html.

See [webmasterworld.com...]

4:18 pm on Apr 3, 2007 (gmt 0)

New User

10+ Year Member

joined:Apr 3, 2007
posts:3
votes: 0


Ok, I can't post personal links... This doesn't work tho:


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>Test</title>
<style type="text/css" media="screen">
@import url( http://example.com/wp-content/themes/brilliantcorners/style.css );
</style>
</head>
<body>
<p>This should be centered, and grey.</p>
</body>
</html>

I'll try and check re: the mime types, thanks (if I use the Web Developer 1.1.3 tools, and try and edit the css, it's editing the right css and displays the preview styled correctly; it's just the main browser doesn't get hold of it)

[edited by: encyclo at 6:48 pm (utc) on April 3, 2007]
[edit reason] see above [/edit]

4:32 pm on Apr 3, 2007 (gmt 0)

New User

10+ Year Member

joined:Apr 3, 2007
posts:3
votes: 0


Thanks for that tip, that's fixed it... Finished! :)
 

Join The Conversation

Moderators and Top Contributors

Hot Threads This Week

Featured Threads

Free SEO Tools

Hire Expert Members