PDA

View Full Version : Creating table with colored column and row


allanf
05-29-2014, 09:17 PM
I need to create a table and want a column with a solid line to make my table pretty for the info displayed. I have that part down. I now want to have a row with a solid line. This is where I'm having trouble, as I can't unmerge table cells after having the column in place.

Any suggestions? Below is my code.

Thanks!


<body>
<table width="100%" border="0">
<tr>
<td width="218">Audio</td>
<td width="2" rowspan="10" bgcolor="#666666">&nbsp;</td>
<td width="10">&nbsp;</td>
<td width="1218">xxxxxxxxx</td>
</tr>
<tr>
<td>&nbsp;</td>
<td width="10">&nbsp;</td>
<td>&nbsp;</td>
</tr>
<tr>
<td>&nbsp;</td>
<td width="10">&nbsp;</td>
<td>&nbsp;</td>
</tr>
<tr>
<td>&nbsp;</td>
<td width="10">&nbsp;</td>
<td>&nbsp;</td>
</tr>
<tr bgcolor="#666666">
<td height="2">&nbsp;</td>
<td width="10" height="2">&nbsp;</td>
<td height="2">&nbsp;</td>
</tr>
<tr>
<td>&nbsp;</td>
<td width="10">&nbsp;</td>
<td>&nbsp;</td>
</tr>
<tr>
<td>&nbsp;</td>
<td width="10">&nbsp;</td>
<td>&nbsp;</td>
</tr>
<tr>
<td>&nbsp;</td>
<td width="10">&nbsp;</td>
<td>&nbsp;</td>
</tr>
<tr>
<td>&nbsp;</td>
<td width="10">&nbsp;</td>
<td>&nbsp;</td>
</tr>
<tr>
<td>&nbsp;</td>
<td width="10">&nbsp;</td>
<td>&nbsp;</td>
</tr>
</table>
</body>
</html>

edbr
05-30-2014, 07:17 AM
just dont use tables do layout and the options are all yours to style

Ricky55
05-30-2014, 08:46 PM
Hi Allan welcome to the forum.

What do you intend to put in this table?

If it's containing data then that's fine other wise Ed is correct you shouldn't use tables to create a layout for many reasons.

d a v e
05-31-2014, 12:19 PM
does adding

cellspacing="0"

do what you want i.e. get a solid grey row