[Zope] calling the default login form

Dieter Maurer dieter@handshake.de
Tue, 20 May 2003 20:17:02 +0200


Marie Robichon wrote at 2003-5-20 17:02 +0200:
 > I have a table of projects generated from a database that I want visible to 
 > even the anonymous user, but want to reload it by getting the  person in 
 > charge of a project to login and displaying an 'edit' link opposite his 
 > projects.
 > 
 > How can I call up the login window so that the person can login and the 
 > following dtml be rendered without having to change the security settings 
 > for this object?
 > 
 > <dtml-if 
 > expr="(_.SecurityGetUser().getUserName()==responsible)or('JobManager' in 
 > _.SecurityGetUser().getRolesInContext(BE))">

You do not tell us what form of authentication you are using:
"HTTP-Authentication" or "Cookie-Authentication".

For "HTTP-Authentication", you raise an "Unauthorized" exception
to get the browsers login dialog.

For cookie authentication, you make a redirect to the
"login" form (you may want to provide more information such
that you can come back after successful login).


Dieter