小弟菜鸟,请问下面的TABLE样式在CSS中该如何写?
<table width="100%" border="0" cellpadding="1" cellspacing="1" bgcolor="#d9d7fc">
<tr>
<td bgcolor="#FFFFFF"> </td>
<td bgcolor="#FFFFFF"> </td>
</tr>
<tr>
<td bgcolor="#FFFFFF"> </td>
<td bgcolor="#FFFFFF"> </td>
</tr>
</table>
<table width="100%" border="0" cellpadding="1" cellspacing="1" bgcolor="#d9d7fc">
<tr>
<td bgcolor="#FFFFFF"> </td>
<td bgcolor="#FFFFFF"> </td>
</tr>
<tr>
<td bgcolor="#FFFFFF"> </td>
<td bgcolor="#FFFFFF"> </td>
</tr>
</table>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>css细线表格</title>
<style type="text/css">
table{
border-collapse:collapse;
}
td{
border:1px solid #f00;
}
</style>
</head>
<body>
<table>
<tr>
<td>细线表格</td>
<td>细线表格</td>
<td>细线表格</td>
</tr>
<tr>
<td>细线表格</td>
<td>细线表格</td>
<td>细线表格</td>
</tr>
<tr>
<td>细线表格</td>
<td>细线表格</td>
<td>细线表格</td>
</tr>
</table>
</body>
</html>
{
background-color: #d9d7fc;
}td
{
background-color: #FFFFFF;
}