This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
I have a jsp page which will display search results. We have pagination and will display 10 records at a time and the resultset will contain 300 records usually.
I have a checkbox for every record and I need to get the selected values of all these 300 records and pass it to another jsp.
What is the best possible way. Currently I am using an arraylist, getting the checked values and putting them in the arraylist and setting the arraylist in session.
But the problem is, suppose the user selects 1 in the first page, clicks next button, selects 2 more in the 2nd time and click the PASS button(to pass the values to another jsp), only the values selected in the first page is there in session.
How can I include the currently selected ones in session.
Not without refreshing the entire page. Which seems like a not-very-nice thing to do every time the user clicks a check box.
You could also have a hidden inline frame ...
Yeah, but that's a lot more unweildly than just using Ajax -- in fact, that's how "Ajax" used to be done before XmlHttpRequest came along... [ June 23, 2006: Message edited by: Bear Bibeault ]
Joined: Feb 17, 2005
Thanks for the suggestions.
Its not a bug. Its just that I am not able to add the latest checkbox values in session without refreshing the page.
As you said, just to add into the session, I dont want to refresh the page.
I know you can use AJAX, I just used it once. SO to use it now would not be ideal.
Are you giving them the option of skipping one page of the form if they feel it doesn't apply? If so then, why not treat nulls as a value for those fields that get skipped when a user clicks the PASS button?