W3C home > Mailing lists > Public > www-validator@w3.org > November 2002

URI Handling Bug With W3C HTML Validator

From: Brian J. Saville <bsaville@espeedient.com>
Date: Tue, 26 Nov 2002 13:40:56 -0500 (EST)
To: <www-validator@w3.org>
Message-Id: <83013823-0185-11D7-8A5C-000393BAB03A@espeedient.com>




The form located at:

http://validator.w3.org/

has what appears to be a bug (maybe a feature!).

If you submit a URL in the Address input box that has multiple query
string parameters, the address is not properly parsed.

Consider the following URL:

http://www.somedomain.com?parameterA=1&parameterB=2

You would expect that the validator would request the URL as it appears
above from the specified web server. Instead it requests this:

http://www.somedomain.com?parameterA=1

The problem lies in that the ampersand is not be properly encoded. This
can be seen by looking at the GET request that is created after
submitting the form with the above address to the validator service. The
GET looks like:

http://validator.w3.org/check?uri=http://www.somedomain.com?parameterA=1
&parameterB=2

In this case, the validator ignores parameter2 thinking that its uri
parameter ends at A=1, when really parameter2 should be included as part
of the uri parameter and passed on to the host web server.

The correct GET should look like this:

http://validator.w3.org/check?uri=http://www.somedomain.com?parameterA=1
%26parameterB=2

Currently this can be corrected by hand by changing any ampersand to %26
either in the Address input box on the form or in the GET request for
the validator in the address bar.

Thanks,
Brian

> ----
Brian J. Saville
Managing Member
eSpeedient Systems, LLC.
225 W. Huron
Suite 217
Chicago, IL 60610

bsaville@espeedient.com (Business)

312-751-9539 (Business)
312-943-3853 (Fax)
847-909-5560 (Cell)
> ----
Received on Tuesday, 26 November 2002 16:25:04 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 25 April 2012 12:14:04 GMT