Re: the LINK element and IE 5.5
by Andrew McFarland <aamcf(at)aamcf.co.uk>
|
Date: |
Sun, 24 Feb 2002 00:15:02 +0000 |
To: |
"'hwg-style(at)hwg.org'" <hwg-style(at)hwg.org> |
In-Reply-To: |
k12 |
|
todo: View
Thread,
Original
|
|
At 16:20 23/02/02 -0500, Jennifer Peterson wrote:
<snip/>
>1. After finalizing the styles I wanted using embedded styles, I copied
>the styles to a '.css' file and inserted the following line in the <head> of
>my html document: <link rel="stylesheet" type="text/css"
>href="http://www.cotopaxi.k12.ec/style/subpage.css"> in order to create an
>external style sheet situation. I now find that the styles are being
>recognized by Netscape 4.75 but not by IE 5.5. The compatibility charts all
>say that the link element works with all browsers.
LINK is recognized for CSS in all common browsers. The problem lies with
your stylesheet. CSS should be text files, but yours looks like a Microsoft
Word document. Like HTML, if you are writing CSS with Word you need to save
then as text only. IE 5.5 can't make head or tail of the CSS, but Netscape
is picking out some of the styles.
>2. Netscape 4.75 insists on displaying my link colors green (a color
>totally unrelated to the palette of my pages) when the styles are in play.
>If I remove the link element (and therefore the associated styles), the link
>colors are displayed correctly.
<snip/>
It probably isn't picking the styles out very well - actually, if you look
at the CSS, your rule for a:link is the first one, so it has all the binary
junk from Word right in front of it. This is probably what is confusing NS4.
I'd check this myself, but its after midnight here. According to the specs,
what should a browser do when confronted with a CSS with random junk at the
start? Ignore the whole thing, or try to pick out the valid bits?
Andrew
HWG hwg-style mailing list archives,
maintained by Webmasters @ IWA