A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Struts. How to submit ID of the selected object.
Joined: Apr 13, 2004
Jun 11, 2004 13:01:00
I have table in
page that shows all users available in the system. I want to submit user_id of selected user to another Action. How can I do this ?
Good luck for yourself.
Author and ninkuma
Joined: Jan 10, 2002
Jun 11, 2004 13:04:00
Moving to the
Asking smart questions
Books by Bear
Joined: Feb 26, 2001
Jun 11, 2004 13:40:00
One common approach is to use a link. Assuming you have a User bean in some scope:
// attribute name: "userBean"
// bean: instance of User, and User.getUserId() == 1
<html:link action="myAction" paramId="id" paramName="userBean" paramProperty="userId">Link to other action</html:link>
This would render
<a href="myAction.do?id=1">Link to other action</a>
Junilu - [
How to Ask Questions
How to Answer Questions
I agree. Here's the link:
subject: Struts. How to submit ID of the selected object.
How do I remove quotes from around string a user inputted in text box?
How to select multiple values using JCheckbox
assigning a function's result to a form field
selecting a table row with 3 columns and sending it to another page.
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2015