How to Create HTML Table

Introduction to table 
  • Table  tag is used to create a table in html.ie  <table>
  • Tables are divided into table rows with the <tr> tag.
  • Table rows are divided into table data with the <td> tag.
  • A table row can also be divided into table headings with the <th> tag.
  • All these tags are in pair.
example:  In below i create a table in which have three row and three column .


  ROWS  (<tr> tag )

   Table Division (<td>)








STEPS 
1  Open Notepad 

2 Write Code 





<!DOCTYPE html>
<html>
<body>
<table>
<tr>
<th>Student Name</th>
<th>Roll Number</th>
</tr>
<tr>
<td>Vinod</td>
<td>01</td>
</tr>
<tr>
<td>Bhim</td>
<td>10</td>
</tr>
<tr>
<td>Vikash</td>
<td>21</td>
</table>
</body>

</html>



Output:


Student Name Roll Number
Vinod 01
Bhim 10
Vikash 21




Share this

Related Posts

Previous
Next Post »