我正在动态创建一个充满值的表...如果有办法在白色和浅灰色之间交替此表的行颜色,我会感到很痛苦。
这是我用来创建表的代码...
while($row = mysql_fetch_array($result))
{
echo "<tr>";
echo "<td>" . $row['name'] . "</td>";
echo "<td>" . $row['width'] . "</td>";
echo "<td>" . $row['height'] . "</td>";
echo "<td>" . $row['normal_fill'] . "</td>";
echo "<td>" . $row['our_fill'] . "</td>";
echo "<td>" . $row['old_price'] . "</td>";
echo "<td>" . $row['price'] . "</td>";
echo '<td><form method="post" action=""><input type="hidden" name="duckdown_id" value="'.$row['duckdown_id'].'" /><input type="submit" name="sumbit" value="Delete" /></form></td>';
echo "</tr>";
}
echo "</table>";