[Web-SIG] Random thoughts

Gregory (Grisha) Trubetskoy grisha at modpython.org
Mon Nov 3 11:19:49 EST 2003



On Mon, 3 Nov 2003, David Fraser wrote:

> I agree, post and query are great, but I don't think "form" should be
> the general term (what about a query parameter in a hyperlink?)

This gets kind of interesting.

The concept of a "form" is described in HTML standard. The concept of a
query is described in the URL RFC.

To the best of my understanding, query data has no standard for storing
fields and values. All it is is "stuff after the question mark"

So when you see:

blah/blah?name=john&age=55

The query data is "name=john&age=55". If you take that query data *and*
treat it as url-encoded form data, then you can say that "name" is "john",
and "age" is "55". But if you don't treat it as form data, then there is
no standard that says you can pass parameters separated by ampresands,
etc.

So based on that I think "form" is actually appropriate.

If you want to get the query string, that should be available as
request.query.

Grisha



More information about the Web-SIG mailing list