[Zope] newbie : req.AUTHENTICATED_USER

cyrille cyrilleml@kbuilder.net
Wed, 16 Oct 2002 12:32:36 +0200


Johan Carlsson [EasyPublisher] wrote:

> At 11:09 2002-10-16 +0200, cyrille said:
>
>> hello,
>> another newbie in Zope World ;o)
>>
>> First question :
>>
>> I 'm logging in Zope in /manage. I can do what I want, no right problem.
>>
>> So I do a little Pythno script for learning
>> #
>> req= container.REQUEST
>> print "auth user: ", req.AUTHENTICATED_USER,"<br>",
>> print "manager property: ", 
>> req.AUTHENTICATED_USER.has_permission('Manage Properties', 
>> context),"<br>",
>> #
>>
>> when I click in "Test" the result is :
>>
>> auth user:  Anonymous User <br>
>> manager property:  None <br>
>> Why it ir "Anonymous" ??? I'm logging has "Cyrille" ......... ;o{
>
>
> That's funny?
> What happens if you change:
>
>   req= container.REQUEST
> to:
>   req= context.REQUEST 


exactly the same thing....
Where is the real user ??? strange ...
I'm using Zope 2.5.1

thanks for you answer ;o)

cyrille

> Regards,
> Johan Carlsson