[whatwg] Parsing: Greater-than characters in doctype

On Sun, 29 Jul 2007 17:23:42 +0200, Simon Pieters <zcorpan at gmail.com>  
wrote:

> On Fri, 29 Jun 2007 11:56:57 +0200, Simon Pieters <zcorpan at gmail.com>  
> wrote:
>
>> IE seems to not emit the token for > that is in quotes anywhere for  
>> both doctypes and bogus comments (or it treats doctypes as bogus  
>> comments):
>>
>>     <!doctype ">" >
>>     <! ">" >
>>     <? ">" >
>>     </ ">" >
>
> (BTW, IE actually treats the last one as an element.)
>
> IE's behavior is weirder still, it seems...

If there's a whitespace character or an equals sign before the " or '  
character then > characters don't end the comment until a matching " or '  
character has been seen. Otherwise > characters end the comment.

Attributes are also parsed in a funny way in IE, but we probably don't  
need to copy that.

>     http://software.hixie.ch/utilities/js/live-dom-viewer/?%3C%21%20%20%22%22%22%3E%22%3E
>     http://software.hixie.ch/utilities/js/live-dom-viewer/?%3C%21%20%20%22%22%20%22%3E%22%3E
>
>> This does not apply to these:
>>
>>     <!-- "-->" -->
>>     <% "%>" %>

-- 
Simon Pieters

Received on Saturday, 1 September 2007 11:40:27 UTC