This week's book giveaway is in the OCPJP forum.
We're giving away four copies of OCA/OCP Java SE 7 Programmer I & II Study Guide and have Kathy Sierra & Bert Bates on-line!
See this thread for details.
The moose likes Struts and the fly likes Multiple Selection Drop Down in Struts Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA/OCP Java SE 7 Programmer I & II Study Guide this week in the OCPJP forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Multiple Selection Drop Down in Struts" Watch "Multiple Selection Drop Down in Struts" New topic
Author

Multiple Selection Drop Down in Struts

sandeep_saluja
Greenhorn

Joined: Jul 16, 2002
Posts: 7
Hi
Is there a way to get both ID and Value of Multiple Selection Drop Down in Struts1.1.
Thanks
Sandeep
Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6
Moving to the struts forum since this is a struts question.
Srikanth Shenoy
author
Ranch Hand

Joined: Jan 24, 2004
Posts: 184
This has got nothing to do with Struts.
The HTTP protocol states that only ID be returned in a drop down (single or multiple)
If you want both to be returned, you have to append both and make it the ID during display and then split them on the server side on submission.
-Srikanth
Author: Struts Survival Guide - Basics to Best Practices


Srikanth Shenoy
Author of Struts Survival Guide : Basics to Best Practices
 
Consider Paul's rocket mass heater.
 
subject: Multiple Selection Drop Down in Struts