Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Custom JSP Tag

 
Khsitiz sharma
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all!

I'm new to java development environment and I want to know how to create a custom jsp tag which iterate over the collection it contains.
for example let us suppose that we have a HashMap<String,Student> lhashMap.
Here Student is a java bean class which have name,rollno and marks attributes.

what I want is a tag which iterates over the HashMap

Please help me
thanks in advance
 
Marilyn de Queiroz
Sheriff
Posts: 9059
12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Khsitiz sharma,
Welcome to JavaRanch. Unfortunately, the Cattle Drive doesn't have any assignments about custom jsp tag creation, so I'm going to move your question to the Jsp forum.
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Do you want to do this as an academic exercise or do you just want the tag?

If you just want the tag, look at JSTL's c:forEach tag.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic