File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Struts and the fly likes How to avoid multiple page submits Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "How to avoid multiple page submits" Watch "How to avoid multiple page submits" New topic

How to avoid multiple page submits

Sri Anand
Ranch Hand

Joined: Mar 06, 2005
Posts: 392
<html:submit property="forward" styleClass="nav_button" tabindex="10" ">
<bean:message key=""/>

I am using above tag for Submitting the page, its taking some time after page gets submitted to hit server and come back mean while user is clicking submit button multiple times how do i avoid this

I tried
<html:submit value="Submit" onKlick="this.disabled=true;submit()"/>

and the javascript validations in "onFormSubmit" method of the form, as below failed

<sslext:form action="/Permits/handleWalkin" focus="regionalOffice" onsubmit="return onformSubmit(); ">

Any suggestions how to go abt this situation
[ October 22, 2007: Message edited by: Raghunandan Mamidala ]
Merrill Higginson
Ranch Hand

Joined: Feb 15, 2005
Posts: 4864
See question 5 of this forum's FAQ.

Consultant, Sima Solutions
Brent Sterling
Ranch Hand

Joined: Feb 08, 2006
Posts: 948
...also, see these links for more on the topic:

- Brent
I agree. Here's the link:
subject: How to avoid multiple page submits
It's not a secret anymore!