W3C home > Mailing lists > Public > html-tidy@w3.org > July to September 2001

Re: Tidy's handling of <noscript>

From: Valen <valen@nic.com>
Date: Mon, 20 Aug 2001 09:44:45 -0400 (EDT)
Message-Id: <200108201344.JAA14659@nic.com>
To: <html-tidy@w3.org>
Cc: "Fred Bone"<Fred.Bone@dial.pipex.com>
Hi All,

Thanks for the several replies.

It is not my intent to disparage Tidy; it is truly a swell piece of work.  I am simply inquiring about a particular behavior.  I guess I had in mind an alternate approach.  It's appropriate that <noscript> or any other element that ought not occur in <head> be placed in <body>. But why should the head-licit <script> tag suffer the same fate? To put it differently, why not process all <head> tags, moving to <body> those that are illicit while leaving in place those that are licit?



-- Original Message --
From: Fred Bone <Fred.Bone@dial.pipex.com>
To: html-tidy@w3.org
Send: 2001-08-19
Subject: Re: Tidy's handling of <noscript>

On 18 Aug 2001, at 19:23, Paul wrote: 

> My HTML contains a sequence like this:
> <html>
> <head>
> <script>
> <!--
>   some script statements here
> // stop hiding -->
> </script>
> <noscript>
> show this stuff when scripting not enabled
> </noscript>
> </head>
> <body> ....
> Tidy's output moves the <noscript> block to within <body>;
specifically as
> the very first thing after <body>.

Seems the best place for it. Where were you expecting it to go? 

What it's actually doing is: 1. finding <noscript> outside of <body>

2. inserting </head><body> so <noscript> is in the right place

3. deleting the now-superfluous <body> you supplied 

> When I move the <noscript> block before the <script> block and
tidy again,
> the tidy output now has BOTH
> the <noscript> and the <script> block within <body>;
neither is in <head>
> any longer.
> Can anyone shed some light on this behavior? -v shows 30th April,

The explanation above covers this case too: Tidy isn't "moving" 
anything, it's inserting the missing <body> prior to <noscript>.

NOCC, http://nocc.sourceforge.net
Received on Monday, 20 August 2001 09:44:45 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 21:38:50 UTC