W3C home > Mailing lists > Public > html-tidy@w3.org > October to December 2002

Re: Tidy bug (malformed URI reference)

From: Bjoern Hoehrmann <derhoermi@gmx.net>
Date: Thu, 05 Dec 2002 19:03:12 +0100
To: Charles Reitzel <creitzel@rcn.com>
Cc: <html-tidy@w3.org>
Message-ID: <3e1f91a5.85680021@smtp.bjoern.hoehrmann.de>

* Charles Reitzel wrote:
>>Indeed, so authors should avoid using spaces or non-ASCII characters in
>>URIs, no matter what scheme.
>
>"Don't do that" is hardly consistent with Tidy's goal of fixing up markup, 
>is it?  We usually only resort to that answer when faced with a 
>functionality conflict or sheer difficulty.  We have neither in this case.

There are two ways to fix the markup, remove the spaces or escape the
spaces. Removing them is impossible without a proper JavaScript parser
that tells Tidy whether the space is significant or not, we don't have
such JavaScript parser. So Tidy must escape the spaces. That's what Tidy
does. If you don't want Tidy to fix URI attribute values, you can use
the --fix-uri config option. I don't see why 'javascript' URIs should be
made a special case and Tidy should output invalid documents by default
when it is able to fix the document.
Received on Thursday, 5 December 2002 13:02:53 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 5 February 2014 23:39:48 UTC