Re: Cougar DTD: Do not use CDATA declared content for SCRIPT

Sunil Mishra (smishra@cc.gatech.edu)
Wed, 24 Jul 1996 18:42:02 -0400 (EDT)


Date: Wed, 24 Jul 1996 18:42:02 -0400 (EDT)
Message-Id: <199607242242.SAA09312@cleon.cc.gatech.edu>
From: Sunil Mishra <smishra@cc.gatech.edu>
To: www-html@w3.org
In-reply-to: <960724182118_369416462@emout13.mail.aol.com> (Jonsm@aol.com)
Subject: Re: Cougar DTD: Do not use CDATA declared content for SCRIPT


\\ In common practice I am seeing:
\\ 
\\ <SCRIPT>
\\ <!--
\\ write whatever you want here
\\ -->
\\ </SCRIPT>
\\ 
\\ This has the advantage of removing the problems with CDATA and end tags.
\\ It also ensure that the scripts will be invisible to older browsers.
\\ It has the disadvantage of putting your scripts into comments.
\\ 
\\ Jon Smirl
\\ jonsm@aol.com

One has to wonder if even that is safe. The problem is that with SGML a
comment is terminated at a --, when encountered, rather than with a
-->. So, if I had a -- in my script, that should technically terminate the
script. Not very safe, especially if you decide to use SGML tools (such as
a validator) for working with your documents.

Sunil