Throw a PageRedirectException and redirect to your confirmation
page.
---- Pat
> -----Original Message-----
> From: Ralph Johnston [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, August 30, 2005 8:11 PM
> To: Tapestry users
> Subject: Re: Preventing multiple form submission within Tapestry
>
> Tom,
>
> Thanks for the reply. That is pretty much what we are doing, but how do
> we reject
> the extra submissions? If we just return from the listener method on
> subsequent
> calls, then the user sees the same page, instead of the confirmation page.
>
> Thanks!
>
> > Ralph Johnston wrote:
> > > Hi, we're working on a project in which we need to submit a form which
> then creates
> > > a record in a database on successful submission. The problem we have
> is that if
> > > someone clicks on the submit button more than once, it creates
> duplicate records of
> > > the record that the person is trying to submit.
> > >
> > > We've searched the mailing list archives (as best we can) with no
> luck. We know
> > > there is a way to prevent this using Javascript. However, not all the
> people using our
> > > form are guaranteed to have Javascript enabled. Therefore, we need a
> way of
> > > disabling the button or creating a semaphore of sorts to prevent
> multiple submissions
> > > that either create the new record or alter it in a drastic way.
> >
> > Why not put a hidden field in the form with a serial number, record the
> > most recent number received for each session, and don't accept form
> > submissions with a number equal or less than the last received?
> >
> > Tom
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]