[Zope] LoginManager and page templates

Hedley Roos hedley@ise.co.za
Mon, 4 Nov 2002 12:28:29 +0200


Hi

I am trying to use page templates as forms for LoginManager, but I can't get
it to work.

>From LoginManager.py (snippet below) I have traced the problem to line (A)

if hasattr(self,'forbiddenPage'):
  if response.unauthorized.__name__=='unauthorized':

  def
lm_unauth(lm=self,request=request,user=user,roles=roles,old=response.unautho
rized):
    request['AUTHENTICATED_USER'] = user
    lm.forbiddenPage(lm, request, needroles=roles)

    if hasattr(lm,'loginForm'):
      lm.loginForm(lm, request, needroles=roles) (A)

    old()

  response.unauthorized = lm_unauth

*Nothing* happens at that line when loginForm is a page template.

Any ideas?

I have tried a workaround using the normal DTML to call a macro and fill a
slot (I really do need the macro for my login form), and the call macro part
works decently, but not the fill slot part.

I'd rather have page templates all round.

Thanks
Hedley Roos
____________________________________________

ISE Technologies (Pty) Ltd
Innovation Centre, Technopark, Stellenbosch, 7650, South Africa
Tel: +27 (0) 21 880 2456
Fax: +27 (0) 21 880 2457
Web: www.ise.co.za
____________________________________________

"The information in this email and in any attachments is confidential and
intended solely for the attention and use of the named addressee(s). This
information may be subjected to attorney and client or other privilege. It
must not be disclosed to any person without ISE Technologies permission."
"Please note that the recipient must scan this e-mail and any attached files
for viruses and the like. ISE Technologies accepts no liability of whatever
nature
for any loss, liability, damage or expense resulting directly or indirectly
from the access of any files that are attached to this message."