• Post Reply Bookmark Topic Watch Topic
  • New Topic

howto make html:link dynamic select item of map ?  RSS feed

Nakata kokuyo
Ranch Hand
Posts: 472
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi good day,

i have a hashmap which hold the information for menu name, and it look like following :

which may result as follow :

then i have a jstl foreach loop for create link as following

this created link is fine if i have hard code it with
request.setAttribute("menu1", "menu1");
request.setAttribute("menu2", "menu2");

and the result will show mke the link pass a parameter to other page which is something like this "menu1.do?menuname=menu1",

but my problem is , i try to avoid hardcode it into request, and prefer to make it dynamically when i have a menu name with "menu1", it will go Hashmap find the key for "menu1" and insert into "paramName" property

can someone guide me how to do so ? thank you
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!