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 2 of 2
  1. #1
    New Coder
    Join Date
    Aug 2008
    Posts
    19
    Thanks
    3
    Thanked 0 Times in 0 Posts

    Exclamation White space under IE Div, not FF

    I have a simple error with a white space under a DIV to another DIV in IE, the code is as follows;

    body{
    font-family:Arial, Helvetica, sans-serif;
    text-align:center;
    margin: 0px auto;
    padding: 0px auto;
    }

    #login_image{
    margin:150 0 0 0;
    padding:0;
    border: 0px auto;
    height: auto;
    }

    #login{
    margin: 0px auto;
    padding: 0px auto;
    border: 0px auto;
    }


    If you could help it would be a big thanks, been looking around the internet for awhile now!

  • #2
    Master Coder Excavator's Avatar
    Join Date
    Dec 2006
    Location
    Alaska
    Posts
    9,667
    Thanks
    22
    Thanked 1,827 Times in 1,811 Posts
    Hello Abakiz,
    A lot of your CSS is wrong there. Take a look at the link about validating CSS in my sig below.


    margin: 0 auto; centers things by making the left/right margins auto. Typically, body is the full width of the browser window so there is nothing to center. In other words, that line does not belong in the styling for the body tag.

    padding: 0 auto; No such thing as auto padding.
    same for border.

    Your #login has margin:150 0 0 0; 150 is a measurement but you have to specify what units your measuring in. The browser sees that and says, "150 what?" Use px, em, % ...



    Oh yes, for your whitespace ... you will need to post your html as well. Seeing only the CSS is not enough.
    A link to the test site would be best but you can post your code here if there is no test site.
    USE the [code] TAGS PLEASE! It puts your code in a scrolling box that greatly helps the readability of your post.
    Last edited by Excavator; 02-24-2009 at 06:41 PM.
    Validate often DURING development - Use it like a splelchecker | Debug during Development |Write it for FireFox, ignore IE
    Use the right DocType | Validate your markup | Validate your CSS | Why validating is good | Why tables are bad


  •  

    Posting Permissions

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