value is disappearing in struts

Posted on 2009-12-21
Last Modified: 2013-11-24
i am developing an application using struts framework

i have  2 inputs. I am doing server side validation. when it is thrwoing validation  errors the value is disappering. what can be done to avoid this. i need to display the value  even after throwing the error

Question by:newbiejava
    LVL 11

    Accepted Solution

    You can put the Action form onto the response before doing the validation. This will ensure that you have all the inputs in the response for use.

    Alternately since the same request is forwarded to the view, the same parameter value should be available in the request even after validation error.
    LVL 40

    Expert Comment

    try doing "redirect=false" in the action mapping

    Similar problem is discussed here in this link


    Author Comment

    This comment has helped partially

    Author Closing Comment

    good solution

    Featured Post

    What Should I Do With This Threat Intelligence?

    Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

    Join & Write a Comment

    Suggested Solutions

    Introduction This article is the first of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article explains our test automation goals. Then rationale is given for the tools we use to a…
    International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
    The viewer will learn how to implement Singleton Design Pattern in Java.
    This tutorial covers a practical example of lazy loading technique and early loading technique in a Singleton Design Pattern.

    734 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    20 Experts available now in Live!

    Get 1:1 Help Now