This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.

Bug 3585 - missing <head> not caught for html 4.01
Summary: missing <head> not caught for html 4.01
Status: RESOLVED INVALID
Alias: None
Product: Validator
Classification: Unclassified
Component: Parser (show other bugs)
Version: HEAD
Hardware: PC Windows XP
: P2 normal
Target Milestone: ---
Assignee: Terje Bless
QA Contact: qa-dev tracking
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-08-07 21:30 UTC by scott coldwell
Modified: 2006-08-08 03:06 UTC (History)
0 users

See Also:


Attachments

Description scott coldwell 2006-08-07 21:30:00 UTC
I attempted to validate code that looked like the following
<doctype 4.01>
<html>

    <title>
  </head>
  <body>
    ...
  </body>
</html>

and it validated. When I changed to xhtml1.0, it raised an error that there was no head element.
Comment 1 Olivier Thereaux 2006-08-08 03:06:34 UTC
http://www.w3.org/TR/html401/struct/global.html#h-7.4.1
says:
The HEAD element
[...]
Start tag: optional, End tag: optional

So the structure you mention, though probably not recommended, and not acceptable in XHTML, is perfectly valid in HTML 4.01.