homepage Welcome to WebmasterWorld Guest from 107.20.34.144
register, free tools, login, search, pro membership, help, library, announcements, recent posts, open posts,
Become a Pro Member
Home / Forums Index / Code, Content, and Presentation / CSS
Forum Library, Charter, Moderators: not2easy

CSS Forum

    
CSS and body tag
syntax or NN 4.X?
Reflect

10+ Year Member



 
Msg#: 253 posted 3:29 pm on Jul 30, 2002 (gmt 0)

Hi,

I have this line in my ext. CSS file...

body { margin-top: 0px; margin-left: 0px; margin-right: 0px; margin-bottom: 0px; font-family: "Lucida Handwriting"; font-size: 18px; font-weight: normal; color: #C7EFF5; background-color: #000; }

All seems to work in IE/Opera but NN won't display <p> text. I thought the body statement was covered under CSS level 1 for NN 4.x support. Is my syntax wrong or is this CSS level 2 and NN 4.X can not display/read it?

Confused,

Brian

 

Nick_W

WebmasterWorld Senior Member nick_w us a WebmasterWorld Top Contributor of All Time 10+ Year Member



 
Msg#: 253 posted 3:42 pm on Jul 30, 2002 (gmt 0)

You dont need those quotes:

body {
margin: 0; /* this will serve just as well */
font- family: Lucida Handwriting; /* you need some backups here */
font-size: 18px;
color: #C7EFF5;
background-color: #000;
}

Nick

rewboss

10+ Year Member



 
Msg#: 253 posted 5:34 pm on Jul 30, 2002 (gmt 0)

NS 4 has some serious problems with CSS, and this is one of the worst: it concerns inheritance.

Basically, block-level text elements, under certain conditions, do not inherit properties as they are supposed to. These "certain conditions", though, just happen to be the most common conditions you will ever meet.

I notice you've set the background colour to black. Drag your cursor across the page; I can guarantee you'll find the text is there... but in the default colour (black) and probably also the default font and size. Black on black is invisible.

The workaround -- which works in most cases, but not all -- is to apply font and colour styles to every block-level and list element you will need. My stylesheets often contain at least one line that begins:

p, blockquote, ol, ul, li, div { ...

Even then it's touch-and-go. The first block-level element after a table or a div can be very unpredictable, and nested lists will resist any attempt to make them behave in any reasonable fashion at all.

Global Options:
 top home search open messages active posts  
 

Home / Forums Index / Code, Content, and Presentation / CSS
rss feed

All trademarks and copyrights held by respective owners. Member comments are owned by the poster.
Home ¦ Free Tools ¦ Terms of Service ¦ Privacy Policy ¦ Report Problem ¦ About ¦ Library ¦ Newsletter
WebmasterWorld is a Developer Shed Community owned by Jim Boykin.
© Webmaster World 1996-2014 all rights reserved