Otto, this is straight out of "Struts in Action" ... it creates a new
actionforward by appending parameters (in this case "dispatch") to the path
of an existing actionforward (in this case "article"):
ActionForward forward = mapping.findForward("article");
StringBuffer path = new StringBuffer(forward.getPath());
boolean isQuery = (path.indexOf("?")>=0);
if (isQuery)
path.append("&dispatch=view");
else
path.append("?dispatch=view");
return new ActionForward(path.toString());
HTH,
Susan
On 10/31/2003 07:48:03 AM "Zorn, Otto" wrote:
> Hi,
>
> I'm very new in struts and I have a little problem:
>
> How can I add own 'key - value - pairs' (parameters) inside an
> action-class to an action-forward?
>
> Hope someone can help me.
> Otto
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]