Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6472517
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T06:21:15+00:00 2026-05-25T06:21:15+00:00

Currently, I have a Stripes form with a submit button that’s binded to the

  • 0

Currently, I have a Stripes form with a submit button that’s binded to the “search” method of the following ActionBean:

public class SearchRepairActionBean extends BaseActionBean {
  private String searchType;
  private String searchValue;

  @DefaultHandler   
  public Resolution defaultHandler(){
    return null;
  }

  @HandlesEvent("search")
  public Resolution search(){   
    return new ForwardResolution("SearchRepairResult.action").addParameter("searchType", searchType).addParameter("searchValue", searchValue);;
  }

  public String getSearchType() {
    return searchType;
  }

  public void setSearchType(String searchType) {
    this.searchType = searchType;
  }

  public String getSearchValue() {
    return searchValue;
  }

  public void setSearchValue(String searchValue) {
    this.searchValue = searchValue;
  }
}

And SearchRepairResultActionBean attempts to resolve it thus:

public class SearchRepairResultActionBean extends BaseActionBean {
private String searchType;
private String searchValue;

@DefaultHandler 
public Resolution defaultHandler(){
    return new ForwardResolution("/jsp/searchRepairResult.jsp");
}

@HandlesEvent("SearchRepairResult")
public Resolution SearchRepairResult(){
    System.out.println(searchType);
    System.out.println(searchValue);    
    }
public String getSearchType() {
    return searchType;
}

public void setSearchType(String searchType) {
    this.searchType = searchType;
}

public String getSearchValue() {
    return searchValue;
}

public void setSearchValue(String searchValue) {
    this.searchValue = searchValue;
}
}

The problem is when I try to print “searchType” and “searchValue” – they return null. Am I passing parameters incorrectly? What would be the best way of doing this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T06:21:15+00:00Added an answer on May 25, 2026 at 6:21 am

    Why are you getting the type and value by calling getContext().getRequest().getParameter()? You should be able to just have methods on your SearchRepairResultActionBean like so:

    public void setType(String type) {
        this.type = type;
    }
    
    public void setValue(String value) {
        this.value = value;
    }
    

    And then Stripes will inject the necessary values in (as part of LifecycleStage.BindingAndValidation) before calling your event method.

    Actually, for that matter, why are you separating SearchRepairActionBean from SearchRepairResultActionBean? If the “result” page needs to view the data that came from the form that was submitted to the search event, then why not just perform the action in the search() method on SearchRepairActionBean, and then do a ForwardResolution on to your view? Is there a particular reason for using two ActionBeans here?

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am currently working with Stripes and I have an ActionBean that loads a
I currently have an MS Access application that connects to a PostgreSQL database via
I currently have a class and I'm trying to create an easy GUI to
I currently have a DetailsView in ASP.NET that gets data from the database based
Learning rails and something smells a little funny. I have the following form for
I am currently implementing a method that accepts two bitmap objects. We can assume
I currently have a site that uses a two-tone background image that is centered
I have a form where users can submit sites and say if they work
I currently have speakers set up both in my office and in my living
I currently have an existing database and I am using the LINQtoSQL generator tool

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.