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 5 of 5
  1. #1
    New to the CF scene
    Join Date
    Sep 2007
    Posts
    2
    Thanks
    2
    Thanked 0 Times in 0 Posts

    Internet Explorer 6 and compatibility

    Hi,

    I have a slight problem with my design. I coded it into xHTML and CSS. Everything seems to work fine and it actually works fine with most of the browsers:

    Safari 3.0.3 - works as it should
    Firefox 2.0.0.6 - works as it should
    Internet Explorer 7 - works as it should
    Opera 9.23 - works as it should
    Internet Explorer 6 - header is out of place

    Can someone tell me how can I fix my design with IE 6? The page itself is here, CSS file is here.

    Thanks,
    dr4cula

  • #2
    Regular Coder
    Join Date
    Feb 2007
    Location
    Canada
    Posts
    924
    Thanks
    10
    Thanked 56 Times in 55 Posts
    Use padding instead of Margin on the header like this:

    Code:
    .header_logo {
        width: 199px;
        padding-left: 9px;
        margin-top: 3px;
        float: left;
    }
    IE gets borked with margins on floated elements.
    Last edited by jlhaslip; 09-17-2007 at 05:27 PM. Reason: typo

  • Users who have thanked jlhaslip for this post:

    dr4cula (09-19-2007)

  • #3
    Supreme Master coder! _Aerospace_Eng_'s Avatar
    Join Date
    Dec 2004
    Location
    In a place far, far away...
    Posts
    19,291
    Thanks
    2
    Thanked 1,043 Times in 1,019 Posts
    IE6 doubles margins if they are in the direction of the float. I wouldn't recommend using padding in this case. You can still use margins but you need to add display:inline;
    Code:
    .header_logo {
    	width: 199px;
    	margin-left: 9px;
    	margin-top: 3px;
    	float: left;
            display:inline;
    }
    ||||If you are getting paid to do a job, don't ask for help on it!||||

  • Users who have thanked _Aerospace_Eng_ for this post:

    dr4cula (09-19-2007)

  • #4
    New to the CF scene
    Join Date
    Sep 2007
    Posts
    2
    Thanks
    2
    Thanked 0 Times in 0 Posts
    Thank you both for your quick answers! Unfortunately I don't have any access to IE6 any time soon, so I will have to test it later on. When I have tested it and it didn't succeed, then I'll let you know. Thank you both again for useful information.

  • #5
    Supreme Master coder! _Aerospace_Eng_'s Avatar
    Join Date
    Dec 2004
    Location
    In a place far, far away...
    Posts
    19,291
    Thanks
    2
    Thanked 1,043 Times in 1,019 Posts
    Quote Originally Posted by dr4cula View Post
    Thank you both for your quick answers! Unfortunately I don't have any access to IE6 any time soon, so I will have to test it later on. When I have tested it and it didn't succeed, then I'll let you know. Thank you both again for useful information.
    Why don't you have access to IE6? Are you on Vista or Windows XP or a Mac?
    ||||If you are getting paid to do a job, don't ask for help on it!||||


  •  

    Posting Permissions

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