You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Davide <da...@aliceposta.it> on 2004/03/21 08:26:56 UTC

HELP! How to check is the session is valid in XSP

Hi all! I would like to check into an xsp if the user is i'm logged or not; 
i'm using the authentication framework. I'd like something like this:

<xsp:page>
...
...
	<if user is logged>
		admin links
	<else>
		lofgn form

<xsp:page>

I'm a beginner with cocoon and i can't resolve this problem. Any Idea?? 
Thanks a lot.

Best Regards, Davide 



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: HELP! How to check is the session is valid in XSP

Posted by Olivier Billard <ob...@jouve.fr>.
Hi Davide,

I think you should check this at sitemap level, using action 
"auth-logged-in" :

<map:match pattern="login">
   <map:act type="auth-loggedIn">
     <map:parameter name="handler" value="applicationhandler"/>

     <!-- User logged in : do some other stuff -->
   </map:act>
   <!-- User not logged in : do some stuff -->
</map:match>


--
Olivier


Davide wrote:
> Hi all! I would like to check into an xsp if the user is i'm logged or 
> not; i'm using the authentication framework. I'd like something like this:
> 
> <xsp:page>
> ...
> ...
>     <if user is logged>
>         admin links
>     <else>
>         lofgn form
> 
> <xsp:page>
> 
> I'm a beginner with cocoon and i can't resolve this problem. Any Idea?? 
> Thanks a lot.
> 
> Best Regards, Davide


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org