0% found this document useful (0 votes)
35 views

HTML Page Structure

The document discusses the evolution of HTML from its initial simple version with no strict syntax rules to XHTML which has stricter XML-based rules, and finally to HTML5 which follows XHTML's strict structure while adding new features like offline application cache and geolocation API. It provides sample code structures for basic HTML, XHTML and HTML5 pages.

Uploaded by

Abhishek Dabar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
35 views

HTML Page Structure

The document discusses the evolution of HTML from its initial simple version with no strict syntax rules to XHTML which has stricter XML-based rules, and finally to HTML5 which follows XHTML's strict structure while adding new features like offline application cache and geolocation API. It provides sample code structures for basic HTML, XHTML and HTML5 pages.

Uploaded by

Abhishek Dabar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

3/30/2020 Playing | Introduction to HTML

HTML
The initial version of HTML was simple and there was no strict syntax rules .i.e. an HTML tag name
can have a small letter or a capital letter. Even, it was not mandatory to close the HTML tag. 

HTML Page Structure

A simple HTML page is given below, where we have used P tag as capital.

1. <html>
2. <head>
3. <title>Html document</title>
4. </head>
5. <body>
6. <P>Your first HTML page</P>
7. </body>
8. </html>

XHTML
XHTML maintenance is easier as compared to HTML because XHTML is based upon XML and
XML syntax rules are strict as compared to HTML. Some of the rules are:

Names of elements and attributes should be in lower case.


All attribute values must be within quotation marks.
Elements which are not empty must end with a closing tag.
Elements which are empty should end with space and a slash.

XTML Page Structure

1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"


2. "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
3.
4. <html xmlns="http://www.w3.org/1999/xhtml">
5. HTML Page Structure
<head>
6. <title>Html document</title>
7. </head>
8. <body>

https://www.dotnettricks.com/player/html/html-introduction-getting-started 1/2
3/30/2020 Playing | Introduction to HTML

9. <p>Your first HTML page</p>


10. </body>
11. </html>

HTML5
HTML5 is the latest standard for HTML. HTML5 is widely accepted to build your modern web
sites. HTML5 follows the strict culture of XHTML along with the following benefits :

Cleaner/Easier markup
Consistency
Supports rich media elements

Offline Application Cache


Geolocation API

HTML5 Page Structure

1. <!DOCTYPE html>
2.
3. <html>
4. <title>Html5 document</title>
5. </head>
6. <body>
7. <p>Your first HTML5 page</p
8. </body>
9. </html>

https://www.dotnettricks.com/player/html/html-introduction-getting-started 2/2

You might also like