• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Remove form fields from URL during forward

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The login information entered by the user in login.jsp is validated by an action ValidateUser. It has the following entry in struts-config file.

<action path="/validateUser"
type="com.struts.actions.ValidateUser"
name="authenticateForm"
scope="page"
validate="false">
<set-property property="secure" value="true"/>
<forward name="success" path="/success.jsp" />
<forward name ="failure" path="/login.do" />
</action>

In ValidateUser class, I check the user credentials and forward the request to success or failure based on the result. My issue is when it forwards to failure, it gets forwarded correctly but the information entered in login.jsp is appended to the url as query string like www.mysite.com/login.do?username=test&password=test.

Can some please help me in removing these fields from the url? I've used post method in login.jsp to submit the form.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic