The <!DOCTYPE> declaration must be the very first thing in your HTML5 document, before the <html> tag.
The doctype declaration is not an HTML tag; it is an instruction to the web browser about what version of the markup language the page is written in.
It is important that you specify the doctype in all HTML documents, so that the browser knows what type of document to expect.
The doctype in HTML 4.01 required a reference to a DTD, because HTML 4.01 was based on SGML. HTML5 is not based on SGML, and does not require a reference to a DTD, but need the doctype for browsers to behave as they should.
Using the tag:
The !doctype declaration in HTML5 has been simplified, all you do is place <!doctype html> as the very first line of your document before your <html> declaration like so:
<!doctype html>And you're done!
<html>
</html>
Catch you guys later.
Good stop if you ever want to learn HTML tricks. Thanks!
ReplyDeletethis is some good stuff man, nice understandable tips
ReplyDeleteThis makes it so I can finally understand HTML. Thanks!
ReplyDeleteHTML was always a pain at school, good to see some trying to help others.
ReplyDeleteI'll be using these to make my blog look a little less blogger-esque lol
ReplyDeleteSweet. Good information!
ReplyDeleteJust starting into html again, good stuff.
ReplyDeleteThanks again for these tutorials. <3 :3
ReplyDeleteVery cool tuts!
ReplyDeleteVery informational and easy to read tutorial! thanks..
ReplyDeletereally really can't wait now :D
ReplyDeleteHTML 5! I need to learn this, I will visit this site everyday!
ReplyDeletethat is eh pretteh cool trick!
ReplyDeleteGod, I'm learning so much form this blog, thanks!
ReplyDeleteI learnt my lesson with HTML, never again.
ReplyDeletegood tips, i actually needed help with this stuff
ReplyDeletefollowing
I know a lot of languages, but this one will be new for me :D
ReplyDeleteah interesting stuff. i learned html when you didn't have to do a doctype
ReplyDelete