SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Guru htown's Avatar
    Join Date
    Mar 2005
    Posts
    676
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Overflow:auto; problem in IE6

    Can someone tell me why this div that has been set to overflow:auto is pushing down the div below it in IE6. There should be about a 5px white gap not a 100px gap. Works fine in IE7, FF, and Safari.

    http://74.220.207.141/~acupunc3/contact.php

    Thanks,
    Houston
    Houston Brown
    Split Light Designs
    Bringing your ideas to light.

  2. #2
    The CSS Clinic is open silver trophybronze trophy
    Paul O'B's Avatar
    Join Date
    Jan 2003
    Location
    Hampshire UK
    Posts
    40,556
    Mentioned
    183 Post(s)
    Tagged
    6 Thread(s)
    Hi,

    If you put rubbish in you get rubbish out

    Your content div has a height of 250px, yet the parent which is #contentWrapper only has a height of 225px - so what's a browser to do?

    Ie decides to expand the elemnt to accomodate your mistake while other browers decide that they will do what you said and keep the parent to 225px height and ignore the overflow. This is where the difference comes form.

    Just remove the height and adjust the padding instead.

    Code:
    #contentWrapper {
        float:right;
        width:474px;
        padding:25px 15px 15px 20px;
    }
    9 times out of 10 if you tell the browser to do something that makes no sense then the resluts are bound to be unreliable


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
  •