W3C home > Mailing lists > Public > www-html-editor@w3.org > July to September 1997

The Problem With <NOSCRIPT>

From: Rev. Bob <rev-bob@full-moon.com>
Date: Mon, 14 Jul 1997 23:19:30 -0400
Message-ID: <33CAEC42.109DE0A8@full-moon.com>
To: hwg-newtech@hwg.org, hwg-html@hwg.org, www-html-editor@w3.org
Has anyone else noticed the fundamental flaw in the <NOSCRIPT> tag as
currently implemented?  Consider the following page (sans DOCTYPE):

<html>
<head>
<title>Document Title</title>
</head>
<body>
<script language="Foo">Boogedy!<br></script>
<noscript>What language is "Foo?"<br></noscript>
End of text.
</body>
</html>

In theory, this is easy to follow; since there is no "Foo" script
language, the <script> content will be ignored and the <noscript>
contents will be shown.  Thus, the display should be:

-=-=-

What language is "Foo?"
End of text.

-=-=-

However, that ain't how it works.  Try it in MSIE 3.x or Communicator
and you'll see absolutely NO output...either way.  Why?  Because while
they don't recognize "Foo" script (thus skipping the <SCRIPT> tag), they
parse <NOSCRIPT> contents *only if scripting is disabled*...whether they
understood the <SCRIPT> tag that immediately preceded it or not.

The HTML 4.0 draft specification only makes matters worse.  It
depreciates the use of the LANGUAGE attribute for <SCRIPT> in favor of
the TYPE attribute.  Y'know, JavaScript 1.0, 1.1, and 1.2 ALL share the
"text/jss" MIME type!  THIS DOES NOT HELP.

Here's what I propose.  Before the LANGUAGE attribute can be
depreciated, it needs a replacement that will adequately substitute for
the information that it provides.  To that end, I propose allowing the
<NOSCRIPT> tag to take the TYPE attribute, as well as developing a new
VER (version) attribute that would apply to both <SCRIPT> and
<NOSCRIPT>.  With those changes, the above page would look like this:

<html>
<head>
<title>Document Title</title>
</head>
<body>
<script   type="text/foo" ver="1.0">Boogedy!<br></script>
<noscript type="text/foo" ver="1.0">
What language is "Foo?"<br>
</noscript>
End of text.
</body>
</html>

In this model, the <NOSCRIPT> tag is activated if the browser does not
understand the script language specified in the type/ver attrbute pair -
in this case, FooScript 1.0.  The code will still degrade well on
non-scripted browsers (identically to the current model), and would
operate better on future browsers.  Unfortunately, nothing short of
manufacturer patches will fix existing browsers.

-- 

 Rev. Robert L. Hood  | http://rev-bob.home.ml.org/
   Rage InfoCentral   | http://rageccg.home.ml.org/
   CCG InfoCentral    | http://rev-bob.home.ml.org/info_cen.html
 Chattanooga, TN LARP | http://paradigms.home.ml.org/
  Get Off The Cross!  | http://gotc.base.org/
Received on Monday, 14 July 1997 23:16:50 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 27 March 2012 18:16:42 GMT