home > 『Web標準の教科書』読者サポートページ > 第6章 第12節
第6章 第12節(p.440-444)
table {
border-collapse: collapse;
border: 1px solid #666;
border-spacing: 0;
empty-cells: show;
}
th {
padding: 5px;
border: 1px solid #666;
}
td {
padding: 5px;
border: 1px solid #666;
}
:
:
<table id="s01" summary="Mozilla Firefoxの歴史。1列目がバージョン、
2列目が名前、3列目がマイルストーン、4列目が英語版公開日。">
<caption>Mozilla Firefoxの歴史</caption>
:
:
table {
border-collapse: collapse;
border: 1px solid #666;
border-spacing: 0;
empty-cells: show;
font-size: 80%;
}
th {
padding: 5px;
border: 1px dotted #666;
}
td {
padding: 5px;
border: 1px dotted #666;
}
:
:
:
:
th {
padding: 5px;
border: 1px solid #666;
background-color: #9cc;
}
td {
padding: 5px;
border: 1px solid #666;
background-color: white;
}
:
:
:
:
th {
padding: 5px;
border: 1px solid #666;
background: #9cc url(/images/th_bcg.gif) no-repeat top left;
}
:
:
caption {
padding-left: 20px;
border-bottom: 1px dotted #666;
background: url(/images/caption_icon.gif) no-repeat center left;
font-weight: bold;
text-align: left;
}
/* 以下はWin IE 4-6、Mac IE 4-5向けのスタイル */
* html caption {
padding-top: 5px;
padding-bottom: 5px;
}