Html5 table tag table tr td, html5tr

Source: Internet
Author: User

Html5 table tag table tr td, html5tr

 

The three most important

<Table> table declaration label

Attribute:

<Tr> line label table row can be created if there is a table

<Td> cell tag table data can be created with rows

Attribute:

<Th> the table head table header is a special type of td. Because the text in the table header is center-bold, it is a little different.

<! -- Table is the table declaration label, tr is a row, and td is a grid -->

<TableBorder = "1" style = "width: 300px ;">

<! -- The border attribute of the board. The larger the value, the more coarse the style is used with css. Set the row width to pixel. -->

<Tr>

<Td>The first line, the first line</Td>

<Td>The first row and the second row</Td>

<Td>First row, third grid</Td>

</Tr>

<Tr>

<Td>Row 3, the first grid</Td>

<Td>Row 3, second</Td>

<Td>Row 3, level 3</Td>

</Tr>

<Br>

<TableBorder = "1" style = "width: 300px ;"><! -- Copy -->

<Tr>

<Td>The first line, the first line</Td>

<Td>The first row and the second row</Td>

<Td>First row, third grid</Td>

</Tr>

<Tr>

<Td>Row 3, the first grid</Td>

<Td>Row 3, second</Td>

<Td>Row 3, level 3</Td>

</Tr>

<Tr>

<Td>Only one grid</Td>

</Tr>

<Tr>

<TdColspan = "3">There is only one grid, three in total</Td>

Table Structure sorting <thead> <tbody> <tfoot>

<Tr> there are multiple rows. Sometimes there is a lot of data and it may not take into account the prefix. the semantics of thead is to force all the content included in thead to be first displayed. while tfoot is adjusted to final. this is a programming Specification

<Table>

<Thead>

<Td>1</Td>

</Thead>

<Tbody>

<Td>2</Td>

</Tbody>

<Tfoot>

<Td>3</Td>

</Tfoot>

</Table>

 

<Caption> table title, outside the box.

Common background attributes for Color Control

Note: This method does not work to set the column color.

 

<Colgrounp>

The first column can only be set to red, and the color of the specified Column cannot be set.

If it is <colgroup> span = 2> <colgroup> span = 2, it can only be the first two columns, not the second column.

Two correct methods

1. First set the color of the first column and then set the color of the second column.

2. Use the col placeholder

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.