SitePoint Sponsor

User Tag List

Results 1 to 8 of 8

Thread: CSS and NN!!!

Hybrid View

  1. #1
    SitePoint Evangelist
    Join Date
    Jun 2001
    Location
    London
    Posts
    423
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    CSS and NN!!!

    Having trouble in NN with a particular style I reference in my external CSS.

    Here is the style attributes:

    .contentbanner
    {
    BACKGROUND-COLOR: #e8f7c2;
    COLOR: #94ce00;
    FONT-FAMILY: Arial, Tahoma;
    FONT-SIZE: 12pt;
    FONT-STYLE: normal;
    FONT-WEIGHT: bold; padding-left: 5px: 1px #000062 solid;
    }

    The problem is that in IE this shows a solid background with the desired font etc. but alas NN shows nothing??

    Any ideas???

  2. #2
    SitePoint Wizard Aes's Avatar
    Join Date
    Jun 2001
    Location
    Oklahoma
    Posts
    3,392
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    You're referring to Netscape 4.x, correct? Background-image, background-color, et cetera doesn't work in Netscape 4.x; niether do most CSS elements. You'll have to use plain old background="" or stop supporting 4.x completely. Sorry; but that's just how it works.
    Colin Anderson
    Ambition is a poor excuse for those without
    sense enough to be lazy.

  3. #3
    SitePoint Evangelist
    Join Date
    Jun 2001
    Location
    London
    Posts
    423
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Cheers

  4. #4
    Anyone seen my cypher? OneChance's Avatar
    Join Date
    Apr 2001
    Location
    Seattle
    Posts
    281
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    The last part of that style looks like it's a displaced border style. I think if you remove it you'll be fine. The end result would be the following, using shorthand to make things look prettier:
    Code:
    .contentbanner
    {
      color: #94ce00;
      background: #e8f7c2;
      font: normal bold 12pt arial, tahoma;
      padding-left: 5px;
    }
    This tested fine on NS 4.08 on Win98.

  5. #5
    SitePoint Wizard Aes's Avatar
    Join Date
    Jun 2001
    Location
    Oklahoma
    Posts
    3,392
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    The proper method of doing it is background-color : <value here> ; however, not background : <value here> ; like you're using OneChance....

    Just so you know.
    Colin Anderson
    Ambition is a poor excuse for those without
    sense enough to be lazy.

  6. #6
    SitePoint Wizard
    Join Date
    Oct 2001
    Location
    Tucson, Arizona
    Posts
    1,858
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Just so you know, Aes, OneChance did it properly by using shorthand to define many sub-properties for the one main property .

  7. #7
    SitePoint Enthusiast
    Join Date
    Oct 2001
    Posts
    60
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    ns4

    Originally posted by Aes
    Background-image, background-color, et cetera doesn't work in Netscape 4.x;
    I haven't had much problems with background properties in NS 4.

    couple of things, be sure you use the whole url of the style sheet, (http://), make sure your classes come after your IDs in the order of your stylesheet. Netscape is very literal and very picky. Also make sure your css and html validate.

    not sure if this makes a difference or not but I dont use uppercase in my selectors. Also if you do not have any content in your class, the background-color will not show, as ns only applies background-color to content, so make sure there is some words or spaces for it to apply the background to.

    dont use shorthand for ns4. tell it everything you want it to do. I dont believe ns4 supports padding-left, try taking that out or just using generic padding:5px;
    use border-width:, border-color:, border-style:

    stevo

  8. #8
    Anyone seen my cypher? OneChance's Avatar
    Join Date
    Apr 2001
    Location
    Seattle
    Posts
    281
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    NS4 actually supports several shorthand properties just fine, background: and font: included. But I do believe it sometimes scoffs at the border: shorthand.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •