cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Carsten Ziegeler" <>
Subject AW: How do you redirect in Actions.
Date Tue, 05 Jun 2001 07:15:28 GMT
> Berin Loritsch wrote:
> IMO, there should be two locations where it would be
> safe and correct to redirect: Sitemap, and Actions.
Currently it is only possible to redirect from the sitemap.

> However, I need to know if I can still redirect from
> Actions.  If not, how will my sitemap know whether
> to redirect or not?
The action's act method returns a map object. 
In the sitemap you can act on exactly this return value:

<map:act type="my_action">
   <!-- If a map object is returned -->
   <map:redirect-to uri="{key_from_map}"/> 
<!-- if no map object (null) is returned: -->
<map:redirect-to uri="otherwise"/>

If you return a map object you can redirect to any value
given in this map by specifying the redirect inside the 
act tag.

If your act method returns null no statement from inside
the act element is called. But the next statement directly
after the act is called.


Open Source Group                        sunShine - b:Integrated
Carsten Ziegeler, S&N AG, Klingenderstrasse 5, D-33100 Paderborn                          mailto: 

> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, email:

To unsubscribe, e-mail:
For additional commands, email:

View raw message