emptyCells 屬性設(shè)置是否顯示表格中的空單元格(僅用于“分離邊框”模式)。
Object.style.emptyCells=hide|show
值 | 描述 |
---|---|
hide | 默認(rèn)。不在空單元格周圍繪制邊框。 |
show | 在空單元格周圍繪制邊框。 |
本例改變空單元格的顯示方式:
<html>
<head>
<script type="text/javascript">
function showEmptyCells()
{
document.getElementById('myTable').style.emptyCells="show"
}
</script>
</head>
<body>
<table border="1" id="myTable">
<tr>
<td>100</td>
<td>200</td>
</tr>
<tr>
<td>300</td>
<td></td>
</tr>
</table>
<input type="button" onclick="showEmptyCells()"
value="Show empty cells">
</body>
</html>
如對本文有疑問,請?zhí)峤坏浇涣髡搲?,廣大熱心網(wǎng)友會為你解答!! 點(diǎn)擊進(jìn)入論壇
Powered by 365建站網(wǎng) RSS地圖 HTML地圖
copyright © 2013-2024 版權(quán)所有 鄂ICP備17013400號