Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New Coder
    Join Date
    Apr 2007
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Trouble maintaining my navigation's width

    Here's what I've got:
    http://www.hiddencrag.com/cs/fixed_home.html
    My problem is that I can't maintain the width of my navigation when I add padding to it in FireFox. Padding the links causes the width of the div to increase by the amount of the padding (in this case 22px). Obviously taking that increase into account would solve the problem, and it does in firefox, but it shrinks the whole thing in IE6. My goal is to have the navigation be 297 px wide in both browsers and 22px of space to the left of the links.
    Thanks,
    Gabe

  • #2
    Senior Coder koyama's Avatar
    Join Date
    Dec 2006
    Location
    Copenhagen, Denmark
    Posts
    1,246
    Thanks
    1
    Thanked 5 Times in 5 Posts
    The weirdness is due to the fact that your page is rendered in quirks mode. This has severe consequences in especially IE. Here you are suffering from the incorrect IE5 implementation of the CSS box model.

    You have this doctype:
    Code:
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
    Instead try this one to ensure that your page will be rendered in standards mode:
    Code:
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
    "http://www.w3.org/TR/REC-html40/strict.dtd">

  • #3
    New Coder
    Join Date
    Apr 2007
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thanks so much!
    I usually use strict 1.0, and am not very familiar with quirks mode or its DTD. It was a friend's site.


  •  

    Posting Permissions

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