+-------[ Garito ]---------------------- | Hi Andrew! | | This is my form code: | | <html> | <head> | <title tal:content="template/title">The title</title> | </head> | <body> | <form method="post" tal:attributes="action here/Logon/absolute_url"> | Usuario: <input type="text" name="__ac_name" /> | Contrase?a: <input type="password" name="__ac_password" /> | <button type="submit">Logar</button> | </form> | </body> | </html> | | And this is the Logon code: | | from AccessControl import getSecurityManager | | usuario = context.acl_users.validate(context.REQUEST) | | print str(usuario) | print getSecurityManager().getUser().getUserName() | | return printed | | Did I understand you? (this code doesn't work ok) | | Where is the mistake?
First, check your Zope log.. there is quite a bit of debugging that XUF pumps out, in case something went astray. It's at the DEBUG level, so you may have to tweak your zope.conf settings to see it. You should get something like; exUserFolder identify returned <someuser>, <somepassword> Secondly, I wouldn't call validate... I would call .authenticate followed by .remember if you wish to change the user. -- Andrew Milton [EMAIL PROTECTED] _______________________________________________ Zope maillist - Zope@zope.org http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )