+ 1
Is it necessary to add the HTML doctype?
Is it necessary to add the HTML doctype in the HTML documents? Does it alter the output?
5 Réponses
+ 5
@Maxel Varley wrote: << if not use doctype means you are using html 4.01 >>
Wrong... If no use of <!doctype>, browsers can not guess wich version is used, and would turn into a 'quircks mode' with older standard basics than Html4 (when there was mostly Netscape and IE as browser choice and they don't provide much compatibility between them ^^
Html4 have specific uggly <!doctype>s dedicated to each of its different flavours, and has been simplified for Html5, but not providing a <!doctype> declaration, will absolutly not turn implicitly your document to be parsed as Html4 specifications :P
https://developer.mozilla.org/en-US/docs/Quirks_Mode_and_Standards_Mode
https://hsivonen.fi/doctype/
+ 4
if you want HTML5 feature you have to add
0
Thank you for the answers.