ad

Monday, December 1, 2025

what is html TR tag

what is html TR tag

web designing theory

HTML tag <tr> tag use create row inside a Table.

row define a row within an html table.functions as container table cells.

Syntax 

 Syntax of HTML <tr> tag


<table>
<tr>
.
. <!-- body tag content visible to webpage-->

</tr>
</table>

how to use TR tag in h

Example 


<!DOCTYPE html>
<html>
    <head>
        <title> HTML TR table tag </title>
    </head>
    <body>
        <tr> Row 1 write content</tr>
        <tr> Row 2 write content</tr>
        <tr> Row 3 write content</tr>
    </body>
</html>

how to use TR tag in html
Explain Program

Step  1] 

<!DOCTYPE html>

This declare the document type.

browser that the document is written in html

Step 2 ]

<html>.... . </html>

html is the root element of the html page.

 Every thing inside it is part of the webpage.

Step 3]

<head>

<head> tag head section of the html page.

<head> section contains information about webpage not appears on the screen.

Step 4]

  <title> HTML TR table tag </title>

<title>  tag on the webpage.appears on the browser tag.

show HTML TR table tag

Step 5]

<body>.....</body>

<body> tag contains  all the visible content of the webpage.

inside <body> show the browser screen.

Step 6]

 
<tr> Row 1 write content</tr>
        <tr> Row 2 write content</tr>
        <tr> Row 3 write content</tr>
 

  • <tr> tag  - table row.
  • normally use inside a<table> tag.
  • contain <td> or <th> cells.
  • use <tr> without a <table> browser will show the text.

Row 1 write content
Row 2 write content
Row 3 write content

Step 7]

closing the Tag


</body>

 </html>

how to use tr tag in html
Output

what is html TR tag




Related Post :-