| Author |
iterating over hashmap using jstl
|
Saniya Ansari
Ranch Hand
Joined: Sep 30, 2002
Posts: 48
|
|
Hi - i have a simple issue but a little new with JSTL. I have a hashmap which contains a key (string value) and value (array list). I need to iterate such that i populate a html drop down list. The key will be displayed, the arraylist[0] and arraylist[1] values will be displayed as text on the HTML page. Can anyone show me a simple example ....thanks!
|
SCJP 2
|
 |
Bear Bibeault
Author and ninkuma
Marshal
Joined: Jan 10, 2002
Posts: 56179
|
|
|
What have you worked out so far?
|
[Smart Questions] [JSP FAQ] [Books by Bear] [Bear's FrontMan] [About Bear]
|
 |
Saniya Ansari
Ranch Hand
Joined: Sep 30, 2002
Posts: 48
|
|
this is what i have so far... but i'm wondering on how to get something like pet.value[0] (refering to the first value in the array list) and then pet.value[1] i.e. the second value... Should i extract out the array list as a variable using the <c:set> tag and print the value at index 0 and 1 from that...
|
 |
Bear Bibeault
Author and ninkuma
Marshal
Joined: Jan 10, 2002
Posts: 56179
|
|
|
Please edit your post and add proper indentation to the code. Thanks.
|
 |
 |
|
|
subject: iterating over hashmap using jstl
|
|
|