I have learnt HTML recently, but not able to clear my concept about <!doctype>
. Please explain <!doctype>
in detail in plain English.
Asked
Active
Viewed 98 times
-1

Nisse Engström
- 4,738
- 23
- 27
- 42

Atish Raina
- 1
- 2
-
4possible duplicate of [What's up, DOCTYPE?](http://stackoverflow.com/questions/414891/whats-up-doctype) – Joffrey Maheo Dec 03 '14 at 09:33
-
You may find [this page](http://stackoverflow.com/questions/6076432/why-do-i-need-a-doctype-what-does-it-do) useful. – Dec 03 '14 at 09:33
2 Answers
1
It;s just the information for web browser about the opened document. Web browser needs to know what kind of document it opens and how to 'read' and display it properly.

KamilD
- 163
- 1
- 7
0
<! doctype>
tag is where your code declares to the browser what kind of standard rest of the code using. There are some kinds of html, like
- HTML 5
- HTML 4.01 Transitional
- HTML 4.01 Frameset
- XHTML 1.0 Strict
- XHTML 1.0 Transitional
- XHTML 1.0 Frameset
- XHTML 1.1
Browsers used to treat codes differently. Its not that much important now but writing a good structured code doesn't hurt anyone.
More information here.