<td>; CSS classes; border-color-top; border-color-left

liunx

Guest
I am trying to outline individual cells with a specific color on all sides using CSS classes. In the code below, "border-top-color" and "border-left-color" don't seem to work. The top and left borders are still black and not red. Why?? This has been driving me nuts...thanks!<br />
<br />
<html><br />
<head><br />
<br />
<style><br />
td.color {<br />
border-width: 5px; <br />
border-top-color:red; <br />
border-bottom-color:red; <br />
border-right-color:red; <br />
border-left-color:red<br />
}<br />
</style><br />
<br />
</head><br />
<br />
<body><br />
<br />
<table border=1 bordercolor="white"><br />
<tr><br />
<td class="color"> cell1 </td><br />
<td> &nbsp; </td><br />
<td class="color"> cell2 </td><br />
<td> &nbsp; </td><br />
<td class="color"> cell3 </td><br />
</tr><br />
</table><br />
<br />
</body><br />
</html><!--content-->Try this for your css...<br />
<br />
td.color {border: 5px solid #FF0000;}<!--content-->Aha...so I just needed the "solid" in there. Thanks!<!--content-->or just add it to your existing CSS:<br />
<br />
<style> <br />
td.color { <br />
border-style: solid;<br />
border-width: 5px; <br />
border-top-color:red; <br />
border-bottom-color:red; <br />
border-right-color:red; <br />
border-left-color:red <br />
} <br />
</style><!--content-->
 
Back
Top