Re: CDATA in elements and attributes

At 23:46 13/04/00 +0200, Terje Bless wrote:
>On 12.04.00 at 14:51, TimP <tim@paneris.co.uk> wrote:
>
>>[The] suggestion on the site is that we get all of [the] web changed to a
>>new cgi-bin standard, which ain't gonna happen :)
>
>Nope, you merely need to properly encode ampersands in href attributes on A
>elements. Do a global search for "&" in URLs and replace them with "&amp;".
>None of your CGI scripts need to be modified, only the calling HTML. This
>works perfectly in all browsers except possibly some older versions of
>Amaya (W3C testbed browser).

Thankyou, I know that that is a proposed solution, but I think it is very ugly. 

I am trying to get an answer to a deeper point.

The definition of CDATA within SGML depends upon whether it is used 
in the context of an element content definition or an attribute definition. 
This 'asymetry'[1] has let us into the position where we have to encode 
VALID urls within HTML. 

I want to understand why this asymetry exists and why it is tolerated.
I really like SGML, and have used it successfully in a few projects, 
(though I would not claim to know it in detail), but I cannot persuade my 
collegues of its benefits whilst it forces the requirement to encode URLs upon them.

yours
timp

[1] I found this term in the validator error help.

Member of http://www.paneris.org/

Received on Thursday, 13 April 2000 20:49:28 UTC