[Maypole] Problem with Cookbook Method
Perrin Harkins
perrin@elem.com
Wed, 12 May 2004 12:24:02 -0400
On Wed, 2004-05-12 at 11:18, Jim Abraham wrote:
> The problem with updating the database and then internally switching to
> another display page, rather than sending a redirect to a display page
> is that, if the user then, for whatever, idiotic reason, clicks Reload
> on that page, he will at the very least get an annoying "POST data"
> message from the browser, or, at worst, repost the edit page and do a
> redundant database write.
And if you redirect the user, you will break the back button. If a
redundant write is a serious problem, it's easy to insert a unique ID in
the form to make sure it doesn't get sent to the database twice. I
think this will come down to a question of what is best for your
particular application.
- Perrin