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 Coder
    Join Date
    Jan 2008
    Posts
    13
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Unexpected whitespace appearing

    Please see my test page here: http://shawnessy.ca/test.html

    The top of my CSS box is "floating" above the rest of the box. It seems to only happen when I include a table in the content section (i.e. "spiffyfg").

    Can someone explain to me why I'm getting that whitespace, and how to fix it?!

    -Quimbly

  • #2
    Senior Coder jcdevelopment's Avatar
    Join Date
    Oct 2007
    Location
    Cowboy Nation
    Posts
    2,182
    Thanks
    174
    Thanked 257 Times in 257 Posts
    put this in ur code

    Code:
    * {
    margin:0px;
    padding:0px;
    }
    then adjust the top margin!!

  • #3
    Master Coder Excavator's Avatar
    Join Date
    Dec 2006
    Location
    Alaska
    Posts
    9,749
    Thanks
    22
    Thanked 1,838 Times in 1,822 Posts
    Hello Quimbly, to show you why, try this once:
    Code:
    .my_header1 {
    color: #FFFFFF;
    font-family: 'Trebuchet MS', 'Lucida Grande', Verdana, Arial, Sans-Serif;
    font-weight: bold;
    font-size: 20px;
    text-align: center;
    margin: 0;
    }
    It's the default margin on p that is causing your gap.

    You should really have a doctype, even when testing.
    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

  • #4
    New Coder
    Join Date
    Jan 2008
    Posts
    13
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thanks, guys!

    What's a doctype?

  • #5
    Master Coder Excavator's Avatar
    Join Date
    Dec 2006
    Location
    Alaska
    Posts
    9,749
    Thanks
    22
    Thanked 1,838 Times in 1,822 Posts
    Quote Originally Posted by Quimbly View Post
    Thanks, guys!

    What's a doctype?
    Check out the link in my sig below...
    OR the sticky at the top of this very forum
    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
    •