Monday, 30 June 2014

HTML Tables!!


Tables are defined with the <table> tag.
The element has a start tag <table> and an end or closing tag </table>.
A table is divided into rows with the <tr> tag. (tr stands for table row)
The element has a start tag <tr> and an end or closing tag </tr>.
A row can also be divided into headings of the table with the <th> tag. (th stands for table heading)
The element has a start tag <th> and an end or closing tag </th>.
A row is divided into data cells/column with the <td> tag. (td stands for table data)
The element has a start tag <td> and an end or closing tag </td>.
The <td> elements are the data containers in the table.
The <td> elements can contain all sorts of HTML elements like text, images, lists, link, images, HTML form, other tables, etc.

[The width of a table can be defined using CSS or defined in table tag inner]

Example:
<table border="1" width="200">
<tr>
  <td>Mukto</td>
  <td>Online</td> 
  <td>100</td>
</tr>
<tr>
  <td>Tunes</td>
  <td>Web</td> 
  <td>100</td>
</tr>
</table>

Output:
Mukto Online 100
Tunes Web 100

If your need help please watch this video:

No comments:

Post a Comment