struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "uma.k" <um...@net-kraft.com>
Subject html:link param value
Date Mon, 27 Dec 2004 12:54:26 GMT
Hi,
I have a problem with html:link tag. I need to pass dynamic param value with
the same key.This is what I am doing

Vector cats = (Vector)request.getAttribute("categories");

HashMap params = new HashMap();

for(int x=0; x < cats.size(); x++)
{
	params.put("category", (String)cats.get(x));
}

pageContext.setAttribute("paramsName", params);

for(int i=0; i < cats.size(); i++)
{
	String catName = (String)cats.get(i);

		%>
			<td><html:link page="/showDetails.do" name="paramsName"
scope="page"><%=catName%></html:link></td>
		<%
}

I see only one dynamic value for all these links, this is because HashMap
overrides the previous key.

How do i solve this?

Uma


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message