武林網(wǎng)(www.survivalescaperooms.com)文章簡(jiǎn)介:表格邊框的處理是CSS網(wǎng)頁(yè)布局中經(jīng)常會(huì)遇到的內(nèi)容,在webjx.com中也有過相關(guān)的介紹,除了將表格作為一個(gè)整體進(jìn)行定義,您也可以將表格邊框的四個(gè)部分分別進(jìn)行定義,包括頂部、底部、左邊和右邊。列表B中的代碼將剛才的例子中的表格分成四個(gè)部分單獨(dú)定義。
表格邊框的處理是CSS網(wǎng)頁(yè)布局中經(jīng)常會(huì)遇到的內(nèi)容,在webjx.com中也有過相關(guān)的介紹,除了將表格作為一個(gè)整體進(jìn)行定義,您也可以將表格邊框的四個(gè)部分分別進(jìn)行定義,包括頂部、底部、左邊和右邊。列表B中的代碼將剛才的例子中的表格分成四個(gè)部分單獨(dú)定義。<html><head><title>HTML Table</title></head>
<style type="text/css">
TABLE {
background: blue;
border-collapse: separate;
border-spacing: 10pt;
border-top: 15px solid red;
border-left: 15px solid red;
border-right: 5px dashed black;
border-bottom: 10px dashed blue; }
TD, TH {
background: white;
border: outset 5pt;
horizontal-align: right; }
CAPTION {
border: ridge 5pt blue;
border-top: ridge 10pt blue; }
</style><body>
<table summary="webjx.com - Tables and CSS">
<caption>First Quarter Sales</caption>
<thead><tr>
<thabbr="salesperson" scope="col">Person</th>
<thabbr="sales" scope="col">Sales</th>
</tr></thead>
<tbody><tr>
<td>Mr. Jin</td>
<td>600.00</td>
</tr><tr>
<td>Mr. Jones</td>
<td>0000.00</td>
</tr><tr>
<td>Ms. Williams</td>
<td>0000.00</td>
</tr></tbody>
<tfoot><tr>
<td colspan="2">Let's sale, sale, sale!</td>
</tr></tfoot></table></body></html>
新聞熱點(diǎn)
疑難解答
圖片精選