我的问题是我试图在 CSS 中创建一个表格,而不影响我在 Fireworks 中创建为表格的导航栏。我尝试使用 ID 和类选择器来定位表,但这没有用。
这是我要在CSS中创建的表:
.cart table {
border-collapse: collapse;
color: #999;
font: 80%/1.2 'Arvo', serif, sans-serif, Georgia, "Times New Roman", Times,serif;
font-weight: normal;
}
.cart table th, td {
border-right: 1px solid #fff;
border-bottom: 1px solid #999;
padding: .5em;
}
.cart table tr {
background: #B0C4D7;
}
.cart table thead th {
background: #fff;
color: #fff;
}
.cart table th {
font-weight: normal;
background: #fff;
}
.cart table tr.alternate {
background: #fff;
}
.cart table tr.alternate th {
background: #fff;
}
HTML代码:
<div class="cart">
<table>
............ info here etc.............
</table>
</div>
导航栏CSS为:
#navigation {
display: block;
text-align: center;
margin: 0 auto;
padding: 0px 0px 0px 0px;
width: 860px;
height: 30px;
}
导航HTML是:
<div id="navigation">
<table border="0" cellpadding="0" cellspacing="0" width="780">
<!-- fwtable fwsrc="navbar.png" fwbase="navbar.gif" fwstyle="Dreamweaver" fwdocid =
"820939584" fwnested="0" -->
<tr>
<td><img name="navbar_r1_c1" src="images/navbar/navbar_r1_c1.gif" width="78"
height="30" border="0" alt=""></td>
<td><a href="index.html" target="_self" onMouseOut="MM_nbGroup('out');"
onMouseOver="MM_nbGroup('over','navbar_r1_c2','images/navbar/navbar_r1_c2_f2.gif',
'images/navbar/navbar_r1_c2_f4.gif',1);"
onClick="MM_nbGroup('down','navbar1','navbar_r1_c2',
'images/navbar/navbar_r1_c2_f3.gif',1);"><img name="navbar_r1_c2"
src="images/navbar/navbar_r1_c2.gif" width="66" height="30" border="0" alt="home"></a>
</td>
..... more cells etc.........
</tr>
</table>