W3C home > Mailing lists > Public > whatwg@whatwg.org > June 2010

[whatwg] Allowing ">" in attribute values

From: Henri Sivonen <hsivonen@iki.fi>
Date: Thu, 24 Jun 2010 01:00:27 -0700 (PDT)
Message-ID: <215643113.538496.1277366427432.JavaMail.root@cm-mail03.mozilla.org>
"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.

Actually, disallowing it would require adding a switch-case to check for '>'. Not checking for it is simpler.

I think we shouldn't disallow harmless stuff just because XML or HTML 4.01 did.

-- 
Henri Sivonen
hsivonen at iki.fi
http://hsivonen.iki.fi/
Received on Thursday, 24 June 2010 01:00:27 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:59:24 UTC