W3C home > Mailing lists > Public > www-html@w3.org > December 1998

Re: &-separator from a form

From: Walter Ian Kaye <walter@natural-innovations.com>
Date: Tue, 22 Dec 1998 14:32:29 -0800
Message-Id: <v03130317b2a5c59ecf4d@[]>
To: www-html@w3.org
At 12:50p -0800 12/22/98, Taco IJsselmuiden wrote:
>Is there any way to define the separator (&) used when using a form ??
><form action=cgi.cgi method=get>
><input type=text name=one value="something">
><input type=text name=two value="another thing">
><input type=submit value="submit">
>would result in this url:
>The problem with this is, that & has a special meaning in HTML, so using
>such an URL in a HTML-page is not perfect.

But the separators never appear in the HTML page when you are using the
<form>...</form>, so it's not a problem there. It's only a problem when
you embed the equivalent URL.

>I could use (i.e.) ; as a separator in the HTML-page, but still most UA's
>use & when data is submitted trough a form. That's not very practical,
>having two different separators.

It's not hard for a CGI to figure out which separator was sent. In my own
Perl library I count the &'s and ;'s, and then determine from the counts
which separator was used, and then split on that.

Received on Tuesday, 22 December 1998 17:32:40 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 15:05:49 UTC