Welcome to WebmasterWorld Guest from 54.146.246.4

Forum Moderators: not2easy

Message Too Old, No Replies

What am I doing wrong-seems simple

Can't get table border to look right in css

     

mfmikeb

8:42 pm on Jul 11, 2004 (gmt 0)

10+ Year Member



I am so bad with css.
Currently, this is the html I have for a table: Currently, the only property (?) I'm using in that "second" class is for the color of the table.

<TABLE ALIGN=CENTER BORDER=3 CELLSPACING=0 CELLPADDING=0 WIDTH="99%" CLASS="SECOND">
<TR>
<TD ALIGN=CENTER>
<a href="http://www.mysite.com/1">TD 1</a>
</TD>
<TD ALIGN=CENTER>
<a href="http://www.mysite.com/2">TD 2</a>
</TD>
<TD ALIGN=CENTER>
<a href="http://www.mysite.com">TD 3</a>
</TD>
</TR>
</TABLE>

In my external css I have this table class
.second { background: #cccccc;
spacing: 0px;
padding: 0px;
border: 5px #000000;
}

When I remove all the orignal table commands on my page the table looks like, well, not a table. Basically a tble with no borders or even seperate cells.
Help?

Rambo Tribble

9:39 pm on Jul 11, 2004 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



If you are trying to get borders on the individual cells, you need to apply the border rule to the td's. As it is, you should have a border around the whole table, only.

Noisehag

9:56 pm on Jul 11, 2004 (gmt 0)

10+ Year Member



See if this is what you are after:

1) Remove the border=3 from the table itself
2) Change your border declaration in your style to border: 5px solid #000000;

Hope that's it.