Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Using validate with different input jsps

 
sandy gupta
Ranch Hand
Posts: 228
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi i have an action mapping called '/register' and 3 of my jsps use that action mapping. Now in case there is an error on the validate of the form bean ( 1 action means 1 form bean ), i need to set the input to the page that sent the request originally so i cannot have a input = ??
hard coded in the action mapping. If i try to set the input parameter of the mapping on the fly, i get an IllegalStateException as the action config is frozen.
Does anyone know how to achieve this.
TIA
S
 
Sazzad Rafique
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I had the same situation. What I did was just writing 3 action mappings having almost the same thing inside except that the "path" and the "input" attrbutes were different. the page mentioned in the input attribute is the place where you mention the page to be shown in case of validation error. though the path attribute is different but the type attribute will be the same for all the three action mappings. so the same action class will handle the action.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic