HTML DOCUMENT STRUCTURE

Eduaction Management 959 Lahore

Code With Jahangir

HTML DOCUMENT STRUCTURE

FREE COURSES

FREE CERTIFICATE

HTML Document Structure

How does an HTML document structure look?

HTML document structure contains some set of tags. Tags are some text enclosed within <…> angle braces. A tag is like a container for either content or other HTML tags. The below text shows how the HTML document structure looks:

<!DOCTYPE html>
<html>
<head>
    <title>Document</title>
</head>
<body>
   <!-- content -->
</body>
</html>

Do not be afraid. I will explain what is being represented above to you.

 

NOTE: These are the five must-use tags for HTML

<!DOCTYPE html><html><head><title><body>

 

1.	<!DOCTYPE html>

The <!DOCTYPE> declaration tag is used by the web browser to understand the version of the HTML used in the document. The current version is 5 i.e. HTML 5.

 

2.	<html>

The <html> tag is the root of an HTML page.

 

3.	<head>

The <head> tag contains page metadata.

 

4.	<title>Document</title>

The <title> tag contains the title of a page and is shown in the browser title bar.

 

5.	</head>

The </head> tag is closing of <head> tag.

 

6.	<body>

<body> tag is the main tag of HTML. It contains the main body of the page and is shown in the white part of the browser.

 

7.	</body>

The </body> tag is closing of <body> tag.

 

8.	</html>

The </html> tag is closing of <html> tag.

 

Every HTML page needs at least these 8 lines to define a layout of a page. We will learn more about HTML tags in the upcoming tutorial.

Eduaction Management 959 Lahore

Code With Jahangir

HTML DOCUMENT STRUCTURE

FREE COURSES

FREE CERTIFICATE

Previous Post Next Post

Contact Form