HI JavaLovers,
i have implemented Token Interceptor concept to restrict the Multiple Form Submission in my application. But its not working in Firefox 11.0 only. In IE and Chrome working fine. I am not able to find the problem also? Please help me on this.
I am applying this concept in Login Page.
IN Login
JSP Page:
<s:form action="loginAct" id="loginForm" method="post" onLoad="autoCompleteOff();" ><br/>
<input type="text" name="strUserID" id="strUserID" value="User ID" onclick="if(this.value == 'User ID') {this.value = '';}" onblur="if (this.value == '') {this.value = 'User ID';}"/><br/><br/>
<input type="password" NAME="strPassword" id="strPassword" value="Password" onfocus="if (this.value == 'Password') {this.value = '';}" onblur="if (this.value == '') {this.value = 'Password';}" onKeyPress="enterKeyPress(event);" autocomplete="off"/><br/>
<input align="middle" type="button" Value="LOGIN" onclick="login()"/>
<s:token/>
<label><a href="#" onclick="gotoForgotPassword();">Forgot Password?</a></label>
</s:form>
In
Struts Page:
<interceptors>
<interceptor-stack name="defaultSecurityStack">
<interceptor-ref name="token">
<param name="excludeMethods">*</param>
<param name="includeMethods">loginExecute</param>
</interceptor-ref>
<interceptor-ref name="ClearCachingInterceptor"/>
<interceptor-ref name="defaultStack"/>
</interceptor-stack>
<interceptor name="SessionCheckInterceptor" class="com.igate.qatool.util.SessionCheckInterceptor" />
<interceptor name="ClearCachingInterceptor" class="com.igate.qatool.util.CachingHeadersInterceptor" />
<interceptor-stack name="testSessionValidationStack">
<interceptor-ref name="SessionCheckInterceptor" />
<interceptor-ref name="defaultStack" />
</interceptor-stack>
</interceptors>
<default-interceptor-ref name="defaultSecurityStack" />
<action name="loginAct" method="loginExecute" class="com.igate.qatool.actions.LoginAction">
<result name="success" type="tiles">/home_page</result>
<result name="failure">/jsp/login.jsp</result>
<result name="tologin" type="redirect">/index.jsp</result>
</action>
This code is working in IE9 and Chrome but its not working in Firefox 11.0