Two Laptop Bag*
The moose likes Struts and the fly likes List from Action to JSP in Struts 1 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "List from Action to JSP in Struts 1" Watch "List from Action to JSP in Struts 1" New topic
Author

List from Action to JSP in Struts 1

Kartik Talasu
Ranch Hand

Joined: Aug 21, 2009
Posts: 98
Hello All,

Am having a JSP where I was suppose to show a dropdown box, where the values of dropdown are in a list which is in request attribute.

So in JSP I had written a scriplet and got the list, and working fine.


But I heard the getting the results from scriplet is not a good practise, so is there any other way to get them?
NOTE: Am using Struts 1



David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

Use the <html:select> and <html:options> or <html:optionsCollection> tags.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: List from Action to JSP in Struts 1
 
Similar Threads
Retain option selected value on submit
dropdown from database
problem with javascript
ArrayList gets duplicate values in JSP
Using AJAX in Struts.... need steps to Implement..