W3C home > Mailing lists > Public > whatwg@whatwg.org > December 2006

[whatwg] Common Subset

From: Alexey Feldgendler <alexey@feldgendler.ru>
Date: Sat, 09 Dec 2006 17:38:28 +0600
Message-ID: <op.tkaimell1h6og4@localhost>
On Sat, 09 Dec 2006 03:15:45 +0600, Michel Fortin  
<michel.fortin at michelf.com> wrote:

> Another noteworthy problem with the common subset about scripting is  
> that it's really impractical to write some idioms. You can't have any  
> instance of "<" or "&" in a script without throwing the document outside  
> of the common subset: HTML requires them to be unencoded, XHTML requires  
> them to be in a CDATA section or escaped as &lt; and &amp;. The CDATA  
> solution would probably work in HTML, although it'd make the document  
> non-conforming.

The HTML5 spec could somehow officially bless CDATA only when used like  
this:

<script>//<![CDATA[
...
//]]></script>

It would not harm because it is already interoperable. But it seems  
somehow stupid to define that <![CDATA[ and ]]> are only allowed inside  
<script> after "//".


-- 
Alexey Feldgendler <alexey at feldgendler.ru>
[ICQ: 115226275] http://feldgendler.livejournal.com
Received on Saturday, 9 December 2006 03:38:28 UTC

This archive was generated by hypermail 2.3.1 : Monday, 13 April 2015 23:08:31 UTC