|external css doesn't always work|
works in some browsers, but not all
I have an external css file that I link with as follows:
<link rel="stylesheet" href="css/mycssfile.css" type="text/css" >
inside my <head> tag.
Among other things, the css file specifies a background color for the body of the document:
It works just fine in Opera 6, in IE5.5, and in Netscape6.2 on my pc. But when the client ran it on their pc, there was no background color. I know they're using IE, but I'm not sure what version. This seems like such a basic thing. Is it possible some versions of IE don't support css?
silly point maybe, but have you uploaded the style sheet? or is their browser set to cache the page and not look for a new version?
If the refernced link is correct for an external CSS it no different than any other link - browser types and versions don't go around saying "stay away from that one".
It is quiet possible though that the client has selected fonts, colors for links, background -- many people like larger font size so they can read easily.
>Among other things, the css file specifies a background color for the body of the document:
Are the other things working?
Although this should work you may want to try background-color
BTW, does the "background: #f7bc5b;" work when you imbed the style in the document?
I've seen this before with my own site. I found it to be rare - but odd because my site has three frames and two used the CSS file but one did not (they all use the same CSS file to reduce bandwidth). The really odd thing, clicking refresh brought it all back nicely!
There must be a minor problem with some browsers.
"background" is the shorthand property for setting all background properties in one rule (-color, -image, -repeat, -attachment, -position) Explorer claimed support for the shorthand rule beginning with v.4, but Netscape did not support it until v.6.
Netscape 4 did not support two of the involved properties (background-attachment and background-position) so they couldn't support the shorthand rule.
Source: W3Schools CSS Background Properties [w3schools.com]
Also, most of the shorthand CSS rules seem to me to have more quirks in their browser support than the "basic" forms, so switching over to background-color:#f7bc5b; sounds like a good suggestion.
Good point tedster... there are many variation to what each browser will support (particularly with Netscape and CSS).
Most of my sites current traffic are 94% IE, so I tend to forget support problems in other browser types.
Thanks for the replies. It turns out my client did have some accessibility settings on their computer set to ignore website colors. It wasn't the internet settings on IE, but the settings in the Windows control panel. Now they're telling me that a lot of websites look different.... No kidding :-0