Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS IE is not my friend :( Adding extra margins to DIVs

  • This topic is empty.
Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #24361

    ssssssssss

    #55063

    an image to illustrate…

    #55069
    Rob MacKay
    Participant

    I will keep saying it lol I might make a macro actually…

    You need to use "position" to position block elements and not margin/padding.

    for example, within positioning :

    margin-top:20px;
    margin-left:20px;

    should be:

    position:absolute/relative; /*absolute is a better option */
    top:20px;
    left:20px;

    IE decides its going to make up its own rules in regaurds to margin and padding, that is why people see such a shift in their designs when position is not used

    #55144

    Hi guys, thanks for the replies.

    Reducing the margins doesn’t seem to help the problem in IE. Is it because I have more than one flash element on the page? Without these elements, all the DIVs align perfectly, but as soon as a second SWF is embedded (either with adobe or SWFObject) the divs move out of position :(

    Its very frustrating! Any further thoughts or ideas guys?

    #55157
    mattvot
    Member

    Would Would something like this not solve the problem if put at the start of the stylesheet?

    Code:
    * { margin:0; padding:0; }
    #55437
    tommyday
    Member

    Are you using a Reset.css?

    Once I started using Eric Meyer’s Reset Reloaded, it drastically cut down on browser inconsistencies.

Viewing 6 posts - 1 through 6 (of 6 total)
  • The forum ‘CSS’ is closed to new topics and replies.