[Web-SIG] Form field dictionaries

Gregory (Grisha) Trubetskoy grisha at modpython.org
Fri Oct 24 14:55:07 EDT 2003



On Fri, 24 Oct 2003, David Fraser wrote:

> The next question is, how do we handle the Get/Post/Both situation?

Just to clarify nomenclature -

POST /blah/blah.py?foo=bar

is a valid request. The part after ? is called "query information", this
is defined in RFC 1808 and RFC1738.

CGI (which has no formal RFC, but there is Ken Coar's excellent draft)
introduces something called "path-info", but its meaning is rather vague
outside of cgi since it relies on a notion of a script, which isn't very
meaningful in most non-CGI environments.

The data submitted in the body of the POST request is called "form data"
and I believe is described in RFC 1867.

I think that query information and form data can be combined in a single
mapping object, because if you want just query data, you can always parse
the url directly via urlparse, and if you want only form data, you can
read and parse it directly as a mime object.

Path-info I think should be left where it belongs - in the cgi-specific
module.

Grisha



More information about the Web-SIG mailing list