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

Re: Tidy's handling of <noscript>

From: Fred Bone <Fred.Bone@dial.pipex.com>
Date: Sun, 19 Aug 2001 14:33:09 +0100
To: html-tidy@w3.org
Message-ID: <3B7FCE25.553.128C2E4@localhost>
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, 2000

The explanation above covers this case too: Tidy isn't "moving" 
anything, it's inserting the missing <body> prior to <noscript>. 
Received on Monday, 20 August 2001 04:52:28 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 3 April 2012 06:13:46 GMT