- From: Anne van Kesteren <annevk@opera.com>
- Date: Thu, 24 Jun 2010 09:43:25 +0200
On Thu, 24 Jun 2010 04:13:56 +0200, Benjamin M. Schwartz <bmschwar at fas.harvard.edu> wrote: > The HTML5 spec appears to allow ">" inside an attribute value. For > example, the following page (note the body tag) passes the experimental > HTML5 validator at w3c.org: > > <!DOCTYPE HTML><html><head><title></title></head> > <body class="3>2"> > </body></html> > > I think ">" should be disallowed inside attribute values. It is > disallowed in XHTML [1]. It is disallowed in HTML 4.01 [2]. Disallowing > it in HTML5 would avoid unnecessary divergence, and also sometimes > simplify parsing. Why would it simplify parsing? It's rather nice to allow it for the <iframe srcdoc> feature. > [1] according to the validator in XHTML 1.1 Strict mode. > > 'character ">" is not allowed in the value of attribute' > > [2] http://www.w3.org/TR/REC-html40/charset.html#h-5.3.2 > > "Similarly, authors should use ">" (ASCII decimal 62) in text instead > of ">" to avoid problems with older user agents that incorrectly perceive > this as the end of a tag (tag close delimiter) when it appears in quoted > attribute values." > > It is also disallowed by the HTML 4.01 Strict validator. -- Anne van Kesteren http://annevankesteren.nl/
Received on Thursday, 24 June 2010 00:43:25 UTC