[Web-SIG] Random thoughts

Gregory (Grisha) Trubetskoy grisha at modpython.org
Mon Nov 3 09:54:31 EST 2003



On Mon, 3 Nov 2003, Thijs van der Vossen wrote:

> Before asking _how_ we might first want to decide if we _should_. What's wrong
> with having both a 'parameters' (query params) and a 'form-data' (posted form
> data) dictionary as attributes of the request object?
>
> In your code you could merge these two with a single line of code:
>
>   merged = request.parameters.update(request.form-data)

The problem here is that this would work great for someone who believes in
separation, but someone who wants these things compbined would need to
have this line in every bit of code.

I think the way to do it would be to somehow provide either behaviour
without additional code, e.g. as an argument to some __init__.

I also think that the combined should be default, with the query string
overriding posted data.

Grisha



More information about the Web-SIG mailing list