external style sheet

They have: 9 posts

Joined: Dec 1999

I have an external style sheet that I want to link to many, many pages and for the most part it works accept for the background color is not transferring to the html pages.
When I edit the html page in Microsoft Front Page the black background is there but not when I open the page. Any suggestions as to why this is happening ?
Thanks

Barry

here is my .css file

<STYLE>
BODY
{
BACKGROUND-COLOR: BLACK;
}
H1
{
COLOR: aqua;
FONT: 32pt arial;
LEFT: 2in;
TEXT-ALIGN: center
}
P
{
COLOR: RED;
FONT: 16pt arial
}
A
{
COLOR: BLUE;
TEXT-DECORATION: none
}
</STYLE>

[This message has been edited by Barry (edited 14 December 1999).]

John Pollock's picture

He has: 628 posts

Joined: Mar 1999

The only thing I can think is that FP is known to change code when you don't want it to once you save the page.

See if it is altering your body tag and adding a background="color" attribute to it, that might override the style sheet you want to use.

If it is, your best bet is to save everything in a plain text editor if possible.

They have: 9 posts

Joined: Dec 1999

Thanks John for the reply
Maybe ????? because I have IE 5 that the background color isn't transferring ?

There isn't any extra body tags in the pages and I have saved everything in my text editor ( notepad ),the background just stays white.
Below is the start of all my HTML pages on my site

<HTML>
<HEAD>
<TITLE>Aerosmith</TITLE>

<META content="text/html; charset=windows-1252" http-equiv=Content-Type>
<META content="MSHTML 5.00.2919.6307" name=GENERATOR>

<LINK REL="stylesheet" TYPE="text/css" HREF="Style3.css">

</HEAD>
<BODY>

and then just all my links and text after that

Thanks again

[This message has been edited by Barry (edited 14 December 1999).]

They have: 9 posts

Joined: Dec 1999

found my mishap....which was in the .css file

The <STYLE> tags (according to W3C CSS Validation Service) were the cause of the Black background not transferring from the .css file to the html page......it said...

unrecognized ----> <STYLE> {background-color: black;}

anyway, seeing as how I'm new to this I thought I'd let ya know just in case any one else was having problems

Thanks

Barry

John Pollock's picture

He has: 628 posts

Joined: Mar 1999

Oooooh! I completely forgot about that, it is right. In the .css file there shouldn't be any style or comment tags, just the style sheet info.

Thanks for posting the solution, now maybe I'll remember that!

Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.