html tbody 用法

字號:


    表格的分組顯示(Structured Table) (IExplore Only)
    1)按行分組
    <thead> ... </thead> - 表的題頭(Header) <tbody> ... </tbody> - 表的正文(Body) <tfoot> ... </tfoot> - 表的腳注(Footer)
    例: <table border> <thead> <tr><th>Food</th><th>Drink</th><th>Sweet</th> </thead> <tbody> <tr><td>A</td><td>B</td><td>C</td> <tr><td>D</td><td>E</td><td>F</td> </tbody> </table>
    2)按列分組
    <colgroup align=#> #=left, right, center
    例: <table border width=160> <colgroup align=left> <colgroup> <colgroup align=right> <thead> <tr><th>Food</th><th>Drink</th><th>Sweet</th> </thead> <tbody> <tr><td>A</td><td>B</td><td>C</td> <tr><td>D</td><td>E</td><td>F</td> </tbody> </table>
    3)列的屬性控制
    <col span=#> #=從左數(shù)起,具有指定屬性的列的列數(shù) <col align=#> #=left, right, center
    例: <table border width=160> <colgroup> <col span=2> <colgroup align=right> <thead> <tr><th>Food</th><th>Drink</th><th>Sweet</th> </thead> <tbody> <tr><td>A</td><td>B</td><td>C</td> <tr><td>D</td><td>E</td><td>F</td> </tbody> </table>