httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Brett E." <>
Subject Re: Patch for query string customization?
Date Mon, 09 Feb 2004 22:03:02 GMT
André Malo wrote:

> * "Brett E." <> wrote:
>>Sorry for the confusion. I meant is it possible to use a #define macro 
>>for the query string delimiter. Ie, everywhere we use '?' in the code, 
>>use say QUERY_STRING_DELIM. For example:
>>     q = strchr(r->filename, '?');
>>     q = strchr(r->filename, QUERY_STRING_DELIM);
>>..everywhere in the code.
> I think, no. The question mark as query string delimiter is well defined in
> several RFCs. Since we implement HTTP, there's no reason to make that
> configurable.
> nd
It is mentioned in the HTML spec:

HTML 4.01 Specification
W3C Recommendation 24 December 1999

The URI that is constructed when a form is submitted may be used as an 
anchor-style link (e.g., the href attribute for the A element). 
Unfortunately, the use of the "&" character to separate form fields 
interacts with its use in SGML attribute values to delimit character 
entity references. For example, to use the URI "http://host/?x=1&y=2" as 
a linking URI, it must be written <A href="http://host/?x=1&#38;y=2"> or 
<A href="http://host/?x=1&amp;y=2">.

We recommend that HTTP server implementors, and in particular, CGI 
implementors support the use of ";" in place of "&" to save authors the 
trouble of escaping "&" characters in this manner.
Another useful link:

So maybe we should conform to the spec and support both styles.

View raw message