• 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

Help ASAP!

 
Ranch Hand
Posts: 56
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Please help me with this:
After doing struts validation(Written own validation methods in form bean), instead of showing the error messages on same page, it is returning to same jsp page but not displaying any error messages. It is showing me blank jsp page with title. Why?? I am using struts 1.2 with tomcat 5.5. I checked that actionErrors object returns correct error messages. Why jsp page is unable to display messages?
JSP page code:

 
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Please read the UseAMeaningfulSubjectLine and UseCodeTags FAQ entries.

Without the action configuration it's impossible to help. Is there anything shown in the server log?
 
namita sasa
Ranch Hand
Posts: 56
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
action config:


Error log says:

2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG AnnualCampaignActionForm3 - actionerror error object inside validate method={recurringAmount=[annualCampaign.errors.recurringAmount.required[]], recurringQuantity=[annualCampaign.errors.recurringQuantity.required[]]}
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG ActionCommandBase - Executing org.apache.struts.chain.commands.servlet.SelectInput
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG AbstractSelectInput - Forwarding back to ForwardConfig[name=null,path=/registration/annualCampaign3.jsp,redirect=false,module=,extends=null,catalog=null,command=null]
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG ActionCommandBase - Executing org.apache.struts.chain.commands.ExecuteCommand
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG ActionCommandBase - Executing org.apache.struts.chain.commands.servlet.SelectForward
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG ActionCommandBase - Executing org.apache.struts.chain.commands.SelectInclude
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG ActionCommandBase - Executing org.apache.struts.chain.commands.servlet.PerformInclude
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG ActionCommandBase - Executing org.apache.struts.chain.commands.servlet.CreateAction
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG ActionCommandBase - Executing org.apache.struts.chain.commands.servlet.ExecuteAction
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG ActionCommandBase - Executing org.apache.struts.chain.commands.ExecuteForwardCommand
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG ActionCommandBase - Executing org.apache.struts.chain.commands.servlet.PerformForward
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG [/paymentsgateway2] - servletPath=/registration/annualCampaign3.jsp, pathInfo=null, queryString=null, name=null
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG PerformForward - Forwarding to /registration/annualCampaign3.jsp
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG [/paymentsgateway2] - Path Based Forward
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG JspServlet - JspEngine --> /registration/annualCampaign3.jsp
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG JspServlet - ServletPath: /registration/annualCampaign3.jsp
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG JspServlet - PathInfo: null
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG JspServlet - RealPath: C:\Program Files\Apache Software Foundation\Tomcat 5.5\webapps\paymentsgateway2\registration\annualCampaign3.jsp
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG JspServlet - RequestURI: /paymentsgateway2/registration/annualCampaign3.jsp
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG JspServlet - QueryString: null
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG JspServlet - Request Params:
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG JspServlet - startDate = 04/29/2009
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG JspServlet - recurringAmount =
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG JspServlet - recurringGiftOption = Weekly
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG JspServlet - recurringQuantity =
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG JspServlet - id = 0
2009-04-28 11:17:53,308 [http-8080-3 ] DEBUG [/paymentsgateway2] - Disabling the response for futher output

From the error log, I found that action error is receiving proper error messages and it is forwarding it back to same jsp page but it is not displaying the error messages.
 
David Newton
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
*Please* read UseCodeTags and then actually use them. It's hard to read code/config without them.
 
namita sasa
Ranch Hand
Posts: 56
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I hope you can read my simplified code with <code> tags around.
 
David Newton
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Did you look at your edited post after you hit "submit" and see that it's not changed?

Here's the link again: UseCodeTags. It tells you *precisely* how to use code tags. After you edit your message you can see, immediately, the effects of your changes (if any): the site redirects you back to the page containing your post.
 
namita sasa
Ranch Hand
Posts: 56
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I changed it to with .
Please let me know about the problem.
 
David Newton
Author
Posts: 12617
IntelliJ IDE Ruby
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
And the validation code? (Did you notice that your last message was formatted improperly because you didn't escape the UBB tags?)
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic