There are probably numerous ways to accomplish this, what I like to do
is define/instantiate the Map using the <jsp:useBean/> tag, then set the
key/value pairs using the <c:set/> tag from JSTL.

<jsp:useBean id="paramsMap" class="java.util.HashMap"/> You MUST to use
a concrete implementation of java.util.Map, not the interface.

<c:set target="${paramsMap}" property="key1" value="myvalue"/>

<c:set target="${paramsMap}" property="key2" value="another value"/>

<html:link action="/someAction" name="paramsMap">Some Where</html:link>

-Adam

-----Original Message-----
From: Garner Shawn [mailto:[EMAIL PROTECTED] 
Sent: Thursday, June 15, 2006 11:24 AM
To: user@struts.apache.org
Subject: [HELP] bean:define and Map

<bean:define id="paramsMap" type="java.util.Map"/>


I get a can not set null value form paramsMap.
How do I specify the key, value pairs?

This is to pass into html:link name="" for request parameters when they
click on the link.

Thanks.
Shawn

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-----------------------------------------
The information contained in this message may be privileged,
confidential, and protected from disclosure. If the reader of this
message is not the intended recipient, or any employee or agent
responsible for delivering this message to the intended recipient,
you are hereby notified that any dissemination, distribution, or
copying of this communication is strictly prohibited. If you have
received this communication in error, please notify us immediately
by replying to the message and deleting it from your computer.

Thank you. Paychex, Inc.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to