Table Colors. HELP! - How do you make the entire table one color? (Posted by jrchomrk)

They have: 3 posts

Joined: Oct 1999

I have a table on my page that lines up some links down the left side. I don't have any borders in the table and I want to have the table a different color than the rest of the page. When I use bgcolor in the <table> tag, all that happens is that the cells turn a different color, but the spaces between the cells don't change color. Is there any way to have the space between cells change color too? Here is a sample of the code I have now:

<table align="left" width="150" bgcolor="white">
<tr><td>First link</td></tr>
<tr><td>Second link</td></tr>
</table>

This code causes the bg behind the text to turn white, but in-between the text-rows, the color isn't changed.
Please Help!
Thanks

Justin S's picture

They have: 2,076 posts

Joined: Jun 1999

Make the cellspacing and cellpadding = "0"

----------
[red]FireBurn Web Publishing[/red]: fireburn.com
Low cost web design, graphic design, and more!

They have: 5,633 posts

Joined: Jan 1970

I think that you will only have this problem with netscape. If you don't want to reduce the cellspacing or cellpadding attribute then you could place another table around the existing one like this.

<table align="left" width="150">
<tr>
<td bgcolor="white">

<table align="left" width="150" bgcolor="white">
<tr><td>First link</td></tr>
<tr><td>Second link</td></tr>
</table>

</td>
</tr>
</table>

----------
[email protected]
http://go.to/hass

Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.