|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
can css set custom borders for a table? (<table>)
Hi all, what i want is to customise the borders of a table...
i know that <div>'s can have custom borders but, for the way that the page works i used table tags <table>. (very little experience of using <div>) is there a way that css can manipulate the borders of a table? i tried using this css: .nmhead { border-color:#cccccc; border-top:border-top-style:none; border-left:border-left-style:none; border-right:border-right-style:double; border-bottom:border-bottom-width:5px; } and then in the table doing this: <td class='nmhead'> but it didnt work (attached is what i want it to look like) any ideas? |
|
#2
|
||||
|
||||
|
Something like this?
Code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>Untitled</title>
</head>
<body>
<style type="text/css">
.nmhead {
border-color:#cccccc;
border-top-style:none;
border-left-style:none;
border-right-style:double;
border-bottom:1px solid #cccccc;
}
.nmhead2 {
border-color:#cccccc;
border-top-style:none;
border-left-style:none;
border-right:1px solid #cccccc;
border-bottom:1px solid #cccccc;
}
</style>
<table cellspacing="0" cellpadding="2">
<tr>
<td class='nmhead'>test 1</td>
<td class='nmhead2'>123</td>
<td class='nmhead2'>123</td>
<td class='nmhead'>123</td>
<td class='nmhead2'>369</td>
</tr>
<tr>
<td class='nmhead'>test 2</td>
<td class='nmhead2'>231</td>
<td class='nmhead2'>231</td>
<td class='nmhead'>213</td>
<td class='nmhead2'>675</td>
</tr>
</table>
</body>
</html>
__________________
Hello, old friend... |
|
#3
|
|||
|
|||
|
Thanks for that
found out the error in my code |
![]() |
| Viewing: Dev Shed Forums > Web Design > CSS Help > can css set custom borders for a table? (<table>) |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|