views:

45

answers:

1

Hi,

I am having an issue with Tomcat and Websphere when users try to login in our application.

If a user presses multiple times the return key after entering his/her login details, the form is submitted multiple times.

Tomcat and Websphere don't ignore the multiple requests and end up complaining about the /j_security_check url not being available.

After the error happens the solution is to restart the browser/tab, in order to get a new session.

Does anyone know of a possible solution to this issue?

Thanks in advance, Paulo

A: 

Use Javascript to disable the button on submit.

<form onsubmit="this.button.disabled=true">
    ...
    <input type="submit" name="button">
</form>
BalusC
It does not help. :(
Paulo Pinto
You need to be more clear about the problem. What do you mean? Don't the button get disabled?
BalusC
I mean that disabling the button does not prevent the multiple requests from happening.
Paulo Pinto
Actually your solution does work. I did see that there was an extra Javascript code that was also triggering submit requests.
Paulo Pinto
Cheers, you're welcome.
BalusC