struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Greg Maletic" <greg.male...@ZeroG.com>
Subject Proper use of HTTP parameters in Struts
Date Wed, 01 Aug 2001 17:21:25 GMT
I'm new to Struts, so if possible, I'd like someone to help clarify the
proper way to deal with HTTP request parameters.

It seems as if there are multiple mechanisms for adding parameters to
requests.  The first is to specify a parameter name as an attribute of an
<action> in the struts-config.xml file.  This single parameter can then
easily be added via the <html:link> tag by adding the appropriate parameter
identifiers, etc.  This approach works pretty well, but it seems to only
allow you to pass one parameter through, which is a significant limitation.

If you want to use multiple request parameters, another approach is to put
the multiple parameters into a Map using RequestUtils.computeParameters(),
then pass the resulting Map into RequestUtils.computeURL(), then pass that
through <html:link> as a "link" attribute.

I have a feeling that I'm not getting how this is supposed to work, because
the idea of having two architectures--one that supports one parameter, an
entirely different one that supports multiple parameters--doesn't make
sense.

Could someone let me know the standard Struts technique for handling these
parameters?

Thanks!

Greg

======================================
Greg Maletic
Chief Technical Officer
Zero G Software, Inc.
514 Bryant Street
San Francisco, CA 94107

tel: +1.415.512.7771 x303
fax: +1.415.723.7244
mailto:greg@ZeroG.com <mailto:greg@ZeroG.com>
http://www.ZeroG.com <http://www.ZeroG.com>

The leading provider of multi-platform software deployment solutions.
======================================


Mime
View raw message