#1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    May 2001
    Location
    Utrecht, The Netherlands
    Posts
    6
    Rep Power
    0

    Valid XHTML & CSS not working in NS6/Opera6


    Hi,

    I made a page using XHTML and CSS and validated both with the W3C validators. When I view the page in IE6, it works fine, but if I view it in NS6.2.2 or Opera 6.01 then the layout is all screwed up.
    Is the validator missing something or is it the browsers' fault (I thought that NS6 was completely standards compliant?). I can't figure it out, so if someone can tell me what I did wrong, please do.

    You can find the page in question at http://maggie.theadventurersguild.net
  2. #2
  3. |<.+#f@#+.&.|
    Devshed Loyal (3000 - 3499 posts)

    Join Date
    Mar 2002
    Location
    norway
    Posts
    3,009
    Rep Power
    1224
    as i just have ie5.0 i can verify the difference.
    but it looked pretty ok in mozilla 0.9.8,
    bit small font.
  4. #3
  5. Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Sep 2003
    Location
    cambs, uk
    Posts
    32
    Rep Power
    12
    it is probably a width thing, ie6 actually MIS-interprets the css rules and displays the boxes how you think they should be displayed - BUT THAT IS WRONG!!!!!!!!!

    So if you are relying on float to keep to divs next to each other and you think the width is correct it may not be and the width is actually over 100% and terefore pushing the 2nd box down a line.

    Tables and IE6 interpretation of css Boxes state that the
    cellpadding/padding are part of a width declaration so a box with a width of 100px and 5px padding(left and rigth) will have 90px of free space inside.

    HOWEVER, the actual css specification [which ns7 and op7 (and earlier versions also) correctly interpret] states that padding is outside this width

    ie if you declare the width: 50% with 5px pading, 2px border and 3px margin (all left and right) your total box width will be constructed as follows


    left margin 3px
    left border 2px
    left padding 5px
    width = 50%
    right padding 5px
    right border 2px
    right margin 3px

    with the result that the space occupied by that box is 50% of screenwidth PLUS 20px
    If my lpis are mvnoig I'm pbrabloy tknalig siht.
  6. #4
  7. |<.+#f@#+.&.|
    Devshed Loyal (3000 - 3499 posts)

    Join Date
    Mar 2002
    Location
    norway
    Posts
    3,009
    Rep Power
    1224
    and the need for restoring this one and a half year old thread was?
  8. #5
  9. Introspective
    Devshed Loyal (3000 - 3499 posts)

    Join Date
    Nov 2001
    Location
    London, UK
    Posts
    3,317
    Rep Power
    111
    lol, but surely you're still struggling with it. Don't tell me the last 18 months have gone totally to waste

    christo
    This is me: http://chris.uk.com
  10. #6
  11. Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Sep 2003
    Location
    cambs, uk
    Posts
    32
    Rep Power
    12
    well bl****y hell, how on earth did I manage that? sorry about that, I think I was probably searching for something similar and stumbled across this without looking at the post date.

IMN logo majestic logo threadwatch logo seochat tools logo