- From: Kynn Bartlett <kynn@idyllmtn.com>
- Date: Thu, 29 Jul 1999 18:22:11 -0700
- To: www-validator@w3.org
What determines the end of the HEAD element if the end (and beginning) tags are omitted? I had understood that it was the presense of elements not found in %head.content + %head.misc that signalled the end of the HEAD element, but when I feed the validator the following file (found at http://www.kynn.com/test.html): <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd"> <TITLE>This is an example of poor HTML</TITLE> <BR> <LINK REL="stylesheet" TYPE="text/css" HREF="style.css"> <BODY> <P>This is an example of poor HTML</P> </BODY> I get this error: Error at line 4: <BR> ^ document type does not allow element "BR" here My expectation was that the <BR> would signal the end of the HEAD element, and <BR> would pass fine, <LINK> would get flagged as something that doesn't belong in a BODY element, and <BODY> would get flagged because there's already a BODY element that started when the <BR> was encountered. This doesn't seem to be the case, though, and the parse tree looks like this: (HTML tags omitted) <HEAD> <TITLE> This is an example of poor HTML </TITLE> <BR> </BR> AHREF CDATA style.css ATYPE CDATA text/css AREL CDATA stylesheet <LINK> </LINK> </HEAD> <BODY> <P> This is an example of poor HTML </P> </BODY> Is this simply my misunderstanding of what should be happening? If so, please illuminate me on how implied tags work. :) -- Kynn Bartlett <kynn@idyllmtn.com> http://www.kynn.com/ Chief Technologist, Idyll Mountain Internet http://www.idyllmtn.com/ Catch the Web Accessibility Meme! http://aware.hwg.org/ Next Online Course starts August 2 http://www.kynn.com/+nextclass "Pissing off comic book fans isn't a business problem, it's a sport." -NK
Received on Thursday, 29 July 1999 21:28:44 UTC