CSS也能控制表格的交替顏色
更新時(shí)間:2006年09月14日 00:00:00 作者:
復(fù)制代碼 代碼如下:
<style type="text/css">
<!--
tr {background-color:expression((this.sectionRowIndex%2==0)?"red":"blue")}
-->
</style>
</HEAD>
<table>
<tr><td>第1行</td><td>第1行</td></tr>
<tr><td>第2行</td><td>第2行</td></tr>
<tr><td>第3行</td><td>第3行</td></tr>
<tr><td>第4行</td><td>第4行</td></tr>
<tr><td>第5行</td><td>第5行</td></tr>
</table>
相關(guān)文章
flex布局下兩端對(duì)齊,不滿(mǎn)左對(duì)齊
這篇文章主要介紹了flex布局下兩端對(duì)齊,不滿(mǎn)左對(duì)齊,需要的朋友可以參考下2022-12-12淺談?dòng)蓀osition屬性引申的css進(jìn)階討論
說(shuō)到position,稍微對(duì)css了解的能馬上說(shuō)出四個(gè)屬性值:static 、relative、absolute、fixed。更深一步去討論,牽扯出諸如上文提到的normal flow、containing block、bfc、margin collapse,base line,有多少人能很好的回答完整呢,所以在此做一個(gè)自己的總結(jié)歸納。2021-05-05CSS:自定多姿多彩的網(wǎng)頁(yè)鏈接下劃線(xiàn)
CSS:自定多姿多彩的網(wǎng)頁(yè)鏈接下劃線(xiàn)...2006-09-09網(wǎng)頁(yè)使用Google Font API(字體)的方法
本文介紹在網(wǎng)頁(yè)中如何使用Google Font API(字體)的方法2013-11-11