CSS won't show for gecko

windows

Guest
I've been working on a clan site on a network called "avidgamers" that lets you write html for pages that are put together. Since it only allows html files, I put the CSS into a file called "style.html". The strage thing is that gecko browers don't load the file at all. IE and opera both load it fine, and firefox loads it when the same stuff is setup offline, but when I put it up it won't load any of it. I Download ed the webdev bar for it and tried viewing the CSS from that and it shows me exactly what it should for the CSS file. The CSS is completely valid so I don't know what the problem is.

If you'd like to look at it, you can go to <!-- m --><a class="postlink" href="http://www.avidgamers.com/TeamNashua/members.php?username=tester&password=testerone">http://www.avidgamers.com/TeamNashua/me ... =testerone</a><!-- m --> thing you may be able to try is using Server Side Includes (i dont know how to, but plenty of other ppl here can help you with this) and include the css on everypage in the header instead of using link in the head. This gets rid of one advantage of css, but if its all you can do its all you can do.

and as for gecko not recognizing it is probably because the extension (.html) is not correct and should be .css. IE is the one not acting correct by allowing it is my guess.Extension has nothing to do with it. In order for the CSS to be recognized as CSS by real browsers it has to be served as "text/css" MIME type by the server.To be a little less subtle than Vladdy, you HAVE to name the file *.css to have a ghost of a chance the server will send it with the proper content type header. *.html will always be served up as text/html.Originally posted by ray326
To be a little less subtle than Vladdy, you HAVE to name the file *.css to have a ghost of a chance the server will send it with the proper content type header. *.html will always be served up as text/html.
... unless you are the one setting up the server ;) ...I don't think serving up .html as text/css would go over too well either. 8)Why don't you just have the CSS file on another host, and link to it? If you only have control over .html files, this seems your only option.I guess that would probably be easiest, although I'm still curious why it only doesn't work with netscape and firefoxThat's been answered- they only accept the CSS file if it has been sent as CSS.Originally posted by IncaWarrior
I guess that would probably be easiest, although I'm still curious why it only doesn't work with netscape and firefox Well we all already knew IE isn't a web browser but now it looks like Opera isn't either.So your definition of a browser is one that ignores <link rel="stylesheet" type="text/css" href=http://www.webdeveloper.com/forum/archive/index.php/"style.html" />
based on the header of the file? It looks to me like it's been defined enough that it's css
Seems like a bug with firefox to me.No, for example if you link to a .php file with CSS in it, it won't work. However, if you send that PHP file as CSS (header('Content-type: text/css');) then it'll work just fine. It's not a bug.Well it should be listening to the author no matter what the header information is.Originally posted by IncaWarrior
Well it should be listening to the author no matter what the header information is. Ah, you're just mad that actual browsers won't accept an HTML file as a CSS file.Originally posted by IncaWarrior
Well it should be listening to the author no matter what the header information is.
I don’t think the type attribute supersedes the MIME type sent by the header — I don’t believe it should, either. The point is you cannot place CSS in an .html file and expect everything to work.Originally posted by Paul Jr
I don’t think the type attribute supersedes the MIME type sent by the header — I don’t believe it should, either. The point is you cannot place CSS in an .html file and expect everything to work. Agreed. Semantic files, you know? All JS in .js, all CSS in .css, all HTML in .html, and all Dynamic stuffs in .php/.asp/.aspx. :pOriginally posted by IncaWarrior
Well it should be listening to the author no matter what the header information is. No, if it's making decisions like that based on file extensions or file content then it's a file browser, not a web browser. A web browser has a conversation based on HTTP and HTTP defines content using content-type headers.well what's the point of putting all that stuff in the <link> tag if it's just going to ignore it all?

Is there a way to alter the header info without going into server side stuffNot that I know of. Seeing as the server sends the headers, I don't see why that'd even be logical.Originally posted by IncaWarrior
well what's the point of putting all that stuff in the <link> tag if it's just going to ignore it all?

Is there a way to alter the header info without going into server side stuff I think you're laboring under the misconception that a web server gives a flip about the content it's serving. It doesn't unless it's doing server parsed HTML and then usually only on specific pages.Well we've already established it was a problem with firefox just ignoring everything I tell it because a header is differentOriginally posted by IncaWarrior
Well we've already established it was a problem with firefox just ignoring everything I tell it because a header is different No, we've already established Firefox was doing what it's supposed to do.No!

I don't care what headers the server sends. If the browser sees ' content="css/text" ' then it should take what ever it's givin as CSSOriginally posted by IncaWarrior
No!

I don't care what headers the server sends. If the browser sees ' content="css/text" ' then it should take what ever it's givin as CSS You know it's supposed to be text/css, right?yes, that's what I have, I just typed it backwards...Originally posted by IncaWarrior
No!

I don't care what headers the server sends. If the browser sees ' content="css/text" ' then it should take what ever it's givin as CSS

no, if there were not strict standards then there would be more room for error. having things strictly layed out allows for problems to be solved easier. Plus a computer does not work the same as the human mind. It processes things differently no matter what some ppl want to think at times :Pwell what's the point of the content attribute if firefox just ignores it?Originally posted by IncaWarrior
well what's the point of the content attribute if firefox just ignores it?

it isnt ignored, but there is just more to it as they explained aboveI don't know that answer to be honest. But I can sure take a quasi-educated guess. I mean what makes you think any browser should take any heed of the other attributes of the tag? I didn't make that assumption. My guess is that it's probably supposed to be used by the same thing that the bulk of stuff in the head gets used by; Search engines. If a search engine sees an address it'd probably go over and investigate. But if it sees rel="stylesheet" and type="text/css" then it knows not to bother as any information found in the file will have no significance to it what so ever. I know that logic is applied when linkinging other documents intended for consumption.
 
Back
Top