サイト内検索

...HTML・XHTMLタグ...

table

罫線(内罫線)

罫線(内罫線)の表示スタイルは、table要素にrules属性を指定します。
[使い方]
<table border="3" rules="none">
属性 属性値 説明
rules= "none"全ての罫線(内罫線)を表示しません。
"rows"行の罫線のみを表示します。
"cols"列の罫線のみを表示します。
"groups"グループの間の罫線のみを表示します。
"all"すべての罫線(内罫線)を表示します。

サンプル

《none・・・全ての罫線(内罫線)を表示しない場合》

[bodyの中]

<table border="3" rules="none">
<tr>
<th>No</th>
<th>No</th>
</tr>
<tr>
<td>No</td>
<td>No</td>
</tr>
</table>

[ブラウザ上]

NoNo
NoNo

《cols ・・・内枠の縦線のみを表示する場合》

[bodyの中]

<table border="3" rules="cols ">
<tr>
<th>No</th>
<th>No</th>
<th>No</th>
</tr>
<tr>
<td>No</td>
<td>No</td>
<td>No</td>
</tr>
</table>

[ブラウザ上]

NoNoNo
NoNoNo

《groups・・・グループの間の罫線のみを表示する場合》

[bodyの中]

<table border="3" rules="groups">
<thead>
<tr>
<th>No</th>
<th>No</th>
</tr>
<tr>
</thead>
<tfoot>
<tr>
<td>No</td>
<td>No</td>
</tr>
</tfoot>
<tbody>
<tr>
<td>No</td>
<td>No</td>
<td>No</td>
<td>No</td>
</tr>
</tbody>
</table>

[ブラウザ上]

NoNo
NoNo
NoNo
NoNo

Copyright c 2007.10.01 luc All rights reserved.