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

  • Home
  • SEARCH
  • 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 6905485
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T08:11:20+00:00 2026-05-27T08:11:20+00:00

I am implementing a simple portal using jsp and struts, the user full fill

  • 0

I am implementing a simple portal using jsp and struts, the user full fill some parameters in a form and i present a table , every elements in the table are readOnly except one , that is a input field that the user could full fill.The table is dynamic and i never know how many rows it would have. So using JSP and struts how can i deal with a dynamic number of input fields ?

For example ,the form have one drop-down list that i implement using the html:select tag from struts taglib and in the ActionForm i have an Array that will be fullfill by the struts framework in every request. If the Array name that contains the possible values from the dropdown is “dropdown” the POST will be something like this "dropdown='value1'&dropdown='value2'" , but i can not implement this solution to the dynamic input fields. I need help.

  • 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-27T08:11:21+00:00Added an answer on May 27, 2026 at 8:11 am

    If you have a setter in your action form named

    public void setDropDown(String[] selectedValues)
    

    then Struts will call it with an array containing all the selected values in all the select boxes named “dropDown”.

    If you have a setter in your action form named

    public void setDropDown(int index, String value)
    

    then Struts will call it once for each select box named “dropDown[i]” where i is an integer identifying each of the rows (one index per row).

    If you have a setter in your action form named

    public void setDropDown(String key, String value)
    

    then Struts will call it once for each select box named “dropDown(key)” where key is the a key identifying each of your rows (one key per row).

    See http://struts.apache.org/1.x/struts-taglib/indexedprops.html for more details

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

Sidebar

Related Questions

I am implementing a simple drop-down using hiccup: ;DATASET/CREATE (defn get-cols-nms [table] This function
I'm Implementing a simple web app using Django, I want to get user's location
I am implementing a simple recommendation system for a collection of user created components.
I am implementing a simple cache using LinkedHashMap based on the instructions found here
I am implementing a simple board game (Breakthrough) using OpenGL (plus GLUT and GLUI).
I am implementing a simple DHT using the Chord protocol in Java. The details
I tried implementing a simple web service into an asp.net application using the tutorial
i am implementing the simple bubble sort algorithm using CUDA, and i have a
I'm implementing a simple twitter client for the iPhone using a UITableView. I fetch
I’m implementing a simple HttpModule, where I want some code to run when the

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.