HTML Elements
The HTML element is everything from the <tag name> (start tag) to the </tag name> (end tag). like <h1>
....</h1>
HTML element is defined by a starting tag and ending tag
Start Tag | End Tag | Content |
---|---|---|
<h1> | </h1> | This is larg heading element. |
<h6> | </h6> | This is smole heading element. |
<p> | </p> | This is paragraph element. |
<a> | </a> | This is link element. |
Example of HTML Elements
HTML components can be settled (this implies that components can contain other components).
The following example contains four HTML elements <html>
, <body>
, <h1>
, <p>
and <a>
Example
Edit it yourself<!DOCTYPE html>
<html>
<head>
<title>Page Title</title>
</head>
<body>
<h1>This is a Heading</h1>
<p>This is a paragraph.</p>
<a href="#">This is a linik</a>
</body>
</html>
Output of HTML Element
Edit it yourselfUnderstand the html example element above:
<html> </html> | This tag informs the browser that it is an HTML document. Text between html tag describes the web document. |
---|---|
<body> </body> | It contains the substance of the report to be shown on the net page. The substance may be an picture, a few content, a few joins, etc. This part represents the body of the internet record, which regularly incorporates headings, content, and passages. |
<p> | It is used for defining a paragraph. |
<h1> to <h6> | It is used for defining a heading text. |
<br> | It is used for a single-line break. |
<img> | It is used for defining an image with a given source. |
<a> | It is used for defining a link. |
<b> | It is used for defining bold text. |