[whatwg] Common Subset

Alexey Feldgendler alexey at feldgendler.ru
Sat Dec 9 03:38:28 PST 2006


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 < and &. 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



More information about the whatwg mailing list