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

Re: Tidy bug (malformed URI reference)

From: Charles Reitzel <creitzel@rcn.com>
Date: Thu, 05 Dec 2002 10:53:50 -0500
Message-Id: <>
To: Bjoern Hoehrmann <derhoermi@gmx.net>
Cc: "Hofmann Juergen (SaW/QSG1) *" <Juergen.Hofmann2@de.bosch.com>, "'html-tidy@w3.org'" <html-tidy@w3.org>

Unfortunately, this is a case of "damned if you do, damned if you 
don't".  Escaping regular URLs is necessary to get them to work properly in 
Netscape browsers.  However, you break Javascript embedded in href 

FWIW, I couldn't find Javascript links <a href="javascript: ...">foo</a> 
described anywhere in the HTML spec.  So we may be in a gray area of 
compliance with the _Recommendation_.  Certainly, the W3C has a track 
record of playing fast and loose with URI attributes (think of XML Namespaces).

take it easy,

At 03:04 AM 12/5/2002 +0100, Bjoern Hoehrmann wrote:

>* Hofmann Juergen (SaW/QSG1) * wrote:
> > In line 76 of the HTML-Source Tidy interpret the javascript
> > code as an URI reference. Further Tidy's-HTML-Output-File
> > is false (%20 instead of spaces).
>The "href" attribute of the "a" element must contain nothing but URI
>references, thus Tidy is right to interpret the value as beeing a URI
>references. URI references must not contain spaces, thus Tidy escapes
>the spaces in your javascript:... URI reference. This is not a bug. If
>you dislike what Tidy does to your URI, you can use the --fix-uri
>configuration option to avoid any escaping of the URI, but then your
>(X)HTML document will be invalid.
Received on Thursday, 5 December 2002 10:50:34 UTC

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