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 6 of 6
  1. #1
    New Coder
    Join Date
    Aug 2007
    Posts
    83
    Thanks
    8
    Thanked 0 Times in 0 Posts

    IE Table Padding/margin?

    Alright, so here's the problem:

    In a page I'm making, I've added a table to put results from an SQL query. The problem is, is that IE adds a margin/padding to the outside of the table on every side. Any ideas on how I'd go about stopping this?

    http://highscores.throstware.com/

  • #2
    Regular Coder
    Join Date
    Oct 2007
    Location
    Glencoe, Ontario, Canada
    Posts
    340
    Thanks
    19
    Thanked 27 Times in 27 Posts
    Try adding * {padding:0; margin:0;} over all ur css.
    Eric "PitbullMean" Melo
    Always Start your layout with*{border:0; margin:0; padding:0;}
    Be sure to Thank ALL Users who give assistance.

  • #3
    Master Coder Excavator's Avatar
    Join Date
    Dec 2006
    Location
    Alaska
    Posts
    9,672
    Thanks
    22
    Thanked 1,827 Times in 1,811 Posts
    Hello NeoMoon,
    I'm not sure about tables...
    To get rid of default margin/padding though, add this bit in highlighted in red to your CSS -
    Code:
    <!--
    * {
    margin: 0;
    padding: 0;
    border: none;
    }
    #mainDiv {
    	position: relative;
    	width: 770px;
    	z-index: 0;
    	overflow: hidden;
    	background-color: #FFFFFF;
    	visibility: visible;
    	margin: 0 auto;
    }
    body {
    	background-color: #000;
    	text-position: center;
    }
    #insideDiv {
    	position: relative;
    	z-index: 2;
    	width: 762px;
    	margin: 0 auto;
    	height: 684px;
    }
    #banner_top {
    	background-color: #FFF;
    	background-image: url(Images/Banner_Top.jpg);
    	background-repeat: no-repeat;
    	height: 145px;
    	width: 762px;
    	top: 4px;
    	position: relative;
    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
    Aug 2007
    Posts
    83
    Thanks
    8
    Thanked 0 Times in 0 Posts
    That didn't seem to change much.

    Though, I didn't know you could use * as a wildcard. Thanks for the knowledge.

  • #5
    Regular Coder
    Join Date
    Oct 2007
    Location
    Glencoe, Ontario, Canada
    Posts
    340
    Thanks
    19
    Thanked 27 Times in 27 Posts
    Its not really a wild card its more of forcing a clean slate before the browser reads the code.
    Eric "PitbullMean" Melo
    Always Start your layout with*{border:0; margin:0; padding:0;}
    Be sure to Thank ALL Users who give assistance.

  • #6
    New Coder
    Join Date
    Aug 2007
    Posts
    83
    Thanks
    8
    Thanked 0 Times in 0 Posts
    Quote Originally Posted by PitbullMean View Post
    Its not really a wild card its more of forcing a clean slate before the browser reads the code.
    Mm, gotcha. Good to know; thank ya.

    Anybody else have a suggestion on how to fix the original problem?


  •  

    Posting Permissions

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