|
-
Mar 22nd, 2013, 03:30 PM
#1
Thread Starter
PowerPoster
[RESOLVED] When declaring the <!DOCTYPE html> for html5 do you need the <html>
I am changing my doctypes to html5
<!DOCTYPE html>
is the <html> tag still necessary ?
Waiting for a full featured smart phone with out marrying a provider
Go Android
Go raiders 
-
Mar 23rd, 2013, 02:12 AM
#2
Re: When declaring the <!DOCTYPE html> for html5 do you need the <html>
-
Mar 23rd, 2013, 02:22 AM
#3
Thread Starter
PowerPoster
Re: When declaring the <!DOCTYPE html> for html5 do you need the <html>
Waiting for a full featured smart phone with out marrying a provider
Go Android
Go raiders 
-
Mar 23rd, 2013, 07:16 AM
#4
Re: When declaring the <!DOCTYPE html> for html5 do you need the <html>
Hi there isnoend07,
Actually, the HTML specification explicitly states that the HTML, HEAD and BODY tags are optional. 
These options do not apply to XHTML.
Source:-
This example code will validate...
Code:
<!DOCTYPE html>
<meta charset="utf-8">
<title>untitled document</title>
Hello world
~ the original bald headed old fart ~
-
Mar 24th, 2013, 05:52 PM
#5
Re: [RESOLVED] When declaring the <!DOCTYPE html> for html5 do you need the <html>
Those links are for HTML4.01, not HTML5 
but you're right in that omitting the html, head, and body tags is still allowed by the HTML5 spec. Keep in mind that IE has a bug relating to omitted tags. And you're much less likely to have rendering problems if you don't omit any tags.
-
Mar 24th, 2013, 06:45 PM
#6
Re: [RESOLVED] When declaring the <!DOCTYPE html> for html5 do you need the <html>
Hi there tr333,
Personally, I am still coding HTM4.0.1 strict with the html, head and body
tags included, unless specific HTML5 elements such as video are required.
~ the original bald headed old fart ~
-
Mar 24th, 2013, 10:25 PM
#7
Re: [RESOLVED] When declaring the <!DOCTYPE html> for html5 do you need the <html>
 Originally Posted by coothead
Hi there tr333,
Personally, I am still coding HTM4.0.1 strict with the html, head and body
tags included, unless specific HTML5 elements such as video are required. 
Sure, but the original question did ask about HTML5
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|