CSS样式我要把所有table里面的td列的字颜色改成黑色,这代码用CSS怎么写?

html-css07

CSS样式我要把所有table里面的td列的字颜色改成黑色,这代码用CSS怎么写?,第1张

你是不是想让表格中某一列的字颜色为黑色?

如果是,你可以在样式表中添加

.tdblack{color:#000}

然后再需要在将字体设成黑色的td标签中添加class="tdblack"

比如:<td

class="tdblack">这里是内容</td>

一.在<head></head>之间插入以下代码

<style

type="text/css">

<!--

body

{

background-color:

#000000

}

-->

</style>

二.<body

bgcolor="#000000">

#000000

就是颜色代码,

000000是黑色