[Zope] Zope Requests - POST vs. GET

Toby Dickenson tdickenson at geminidataloggers.com
Tue Dec 16 03:48:44 EST 2003


On Tuesday 16 December 2003 06:35, Tino Wildenhain wrote:
> Passin, Tom schrieb:
>
> >  A GET is supposed to be
> > idempotent, a POST need not be.  For example, if you GET an airline
> > schedule twice in a row, it should not have changed because of the
> > effect of any data you sent with the GET.  If you transfer money from
> > one bank account to another using a POST, you expect to see a change in
> > the state of the resource (your bank account's representation).

> This semantic you are referring to is effectively non existent. Sorry.
> If you see real world examples there are a lot of cases where the
> information indeed changes between GET requests. Even a GET request
> without QUERY-string is a GET request after all.

That is not the distinction that Tom was referring to. Of course that data can 
change *between* GET requests, but it should not change *because* of the GET.

> See for example the shop, where you put items in a backet. On each
> page there is the number of items currently in the basket displayed.
> So no matter if you put it in via GET or POST at least another GET
> will give you different result.
> Its just not feaseable to do it any other way (e.g. only use POST
> for modifying data)

A shop that uses GET for the 'add to basket' operation will suffer from 
problems where it sees more that one such request, when the user thought he 
issued only a single request. This is allowed. Real world http proxies do do 
this automatically.

-- 
Toby Dickenson




More information about the Zope mailing list