Iterating over hashmap injsp in struts application

Posted by Rozer on Stack Overflow See other posts from Stack Overflow or by Rozer
Published on 2010-06-15T10:52:18Z Indexed on 2010/06/15 11:02 UTC
Read the original article Hit count: 161

Filed under:
|

I have a Hashmap object that i am getting on a jsp page.

HashMap<Integer,Gift_product> gift_hm = new HashMap<Integer,Gift_product>();
gift_hm.put(17,new Gift_product("doll",67));

now i need to iterate this and display content on jsp. as Gift_product class contains two fields name and price

jsp output should be

serial no.           product name     price
17                    Doll            67

How can i achieve it..

© Stack Overflow or respective owner

Related posts about java

Related posts about struts