cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Carsten Ziegeler" <>
Subject AW: [C2]: Request/Response cleanup?
Date Tue, 10 Apr 2001 15:11:39 GMT
> Per Kreipke wrote:
> Giacomo wrote:
> > There are other nice things _not_ in C2 because of some good reason.
> > Why is redirection nice? What's the use case for rediretion inside
> > components (includes XSP pages) ?
> Maybe I should be doing things differently, but here a couple of 
> cases I use
> redirects for:
> - login: if the user accesses a restricted page before logging 
> in, they get
> redirected to a login page. And of course back to the referrer when they
> have successfully logged in.
> - private pages: if the users tries to access a 'private' (logged 
> in, but no
> permissions to the page) page, they get redirected out of the hierarchy to
> prevent fishing around for content.
> - form handling: we try to use a MVC paradigm in our cocoon webapps. This
> implicitly uses redirects: the form posts to the controller which handles
> the post and redirects to the results or errors.
> - validation: I use XSP in the controller to validate passwords and form
> fields. Depending on their success, I redirect to different places.
> If these are covered using the sitemap redirector, great. If not, not so
> good.
We have build components with equal features, all of them are Actions which
work like the way Giacomo suggested earlier in this thread.

I personally don't like the redirects in the xsp pages (or in any other 
sitemap component) as the these components build the *content* for the 
request and therefore should not contain any application flow logic. 
The sitemap is the place for the flow logic.


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

View raw message