Join the social network of Tech Nerds, increase skill rank, get work, manage projects...
 
  • Table in HTML

    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 290
    Comment on it

    With the help of HTML table, we can arrange the data in a proper format. HTML table consist of rows and columns.we use various tags for creating HTML table.
    Tags used for creating HTML table:-

    • Table :- This is the very first tag for creating HTML table. Closing of table tag is necessary after opening of the table tag.We insert all the data in the table tag using rows and columns.
    • <table>.......</table>
      

    • Row :- We use the <tr> tag to define each row in the table. The tr tag is mandatory to close after opening it. is closed after completing the cells in a particular row of the table.
    • `<tr>`.......`</tr>`
      

    • Column :- We use the <td> tag to define the columns/cells in each row of the table.It is also mandatory to close the tag after opening it. <td> tag is closed before the closing of row tag(<tr>).
    • <td>.....</td>
      

      Example of creating table : -

      !DOCTYPE html>
      <html>
      <body>

      <table border="1" style="width:100%"> <tr> <td>NAME</td> <td>ADDRESS</td>
      <td>ID</td> </tr> <tr> <td>Priya</td> <td>Dehradun</td>
      <td>121</td> </tr> <tr> <td>Abhinav</td> <td>Delhi</td>
      <td>80</td> </tr> <tr> <td>Ankit</td> <td>Ambala</td> <td>45</td> </tr> </table>

      </body> </html>

    NAME ADDRESS ID
    Priya Dehradun 121
    Abhinav Delhi 80
    Ankit Ambala 45

 0 Comment(s)

Sign In
                           OR                           
                           OR                           
Register

Sign up using

                           OR                           
Forgot Password
Fill out the form below and instructions to reset your password will be emailed to you:
Reset Password
Fill out the form below and reset your password: