Register

If this is your first visit, please click the Sign Up now button to begin the process of creating your account so you can begin posting on our forums! The Sign Up process will only take up about a minute of two of your time.

Results 1 to 4 of 4

Thread: Table Cells

  1. #1
    Junior Member
    Join Date
    Dec 2006
    Posts
    16
    Member #
    14537
    Whenever I make a table with cells there is a small space between each of the cells. Is there away to get rid of this space? If I have two cells next to each other with separate background colors, and a white background behind that, there will be a little white strip between the 2 colors. Also I have been using Dreamweaver.

  2.  

  3. #2
    Senior Member
    Join Date
    May 2003
    Location
    UK
    Posts
    2,354
    Member #
    1326
    Are you familar with CSS?

    The equivalent to the HTML table attribute cellpadding is padding.

    However getting this to work identical to cellpadding can be a pain.

    However this dummy code fixes your problem.

    HTML Code:
    <html>
    
    <head>
    
    <title>table cells</title>
    
    <style type="text/css">
    
    	td.firstTd {background: #99ccff; border: 1px solid black;}
    	td.secondTd { background: #666666; border: 1px solid red; }
    	table { border-collapse: collapse;}
    
    </style>
    
    </head>
    
    <body>
    
    <table width="400">
    	<tr>
    		<td class="firstTd" valign="top">lorem</td>
    		<td class="secondTd" valign="top">ipsum</td>
    	</tr>
    </table>
    
    </body>
    </html>
    I just chucked in some borders just for clarity, the border-collapse: collapse.. collapses more than 1 borders together.

    Good Luck

  4. #3
    Junior Member
    Join Date
    Dec 2006
    Posts
    16
    Member #
    14537
    Thanks alot. I figured out my problem. I was just being a moron

  5. #4
    Senior Member
    Join Date
    May 2003
    Location
    UK
    Posts
    2,354
    Member #
    1326
    Can you state your problem/solution?

    My method works, but incase someone else has the same problem, having an answer in here will help them.


Remove Ads

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
All times are GMT -6. The time now is 11:07 PM.
Powered by vBulletin® Version 4.2.3
Copyright © 2019 vBulletin Solutions, Inc. All rights reserved.
vBulletin Skin By: PurevB.com