js實現表格隔行變色--與jQuery的對比

使用jquery則只須要jquery

$(function(){
$('#tbStu tr:nth-child(even)').addClass('trOdd');
})spa

複習    table表格blog

可選屬性   border 規定表格邊框的寬度io

                 cellpadding  規定單元邊沿與其內容之間的空白table

                 cellspaceing 規定單元格之間的空白function

相關文章
相關標籤/搜索