Hello:
I have a problem, I do not know if this is a bug or I'm making
something wrong!!! I add this:
auth=Auth(globals(),self.db)
auth.define_tables()
mail=Mail() # mailer
mail.settings.server='localhost:25' # your SMTP server
mail.settings.sender='[email protected]' # your email
mail.settings.login=None # your credentials or None
'username:password'
auth.settings.mailer=mail # for user email
verification
auth.settings.registration_requires_verification = False
auth.settings.registration_requires_approval = True
auth.messages.verify_email = 'Click on the link
http://.../user/verify_email/%(key)s to verify your email'
Everything works fine, the problem is when I change the
registration_requires_verification to True:
auth.settings.registration_requires_verification = True
And when I try to register a new user I received this error:
Traceback (most recent call last):
File "/home/web2py/gluon/restricted.py", line 173, in restricted
exec ccode in environment
File "/home/web2py/applications/t4/controllers/default.py", line
243, in <module>
File "/home/web2py/gluon/globals.py", line 96, in <lambda>
self._caller = lambda f: f()
File "/home/web2py/applications/t4/controllers/default.py", line 4,
in user
return dict(form = t2.auth())
File "/home/web2py/gluon/tools.py", line 698, in __call__
return self.register()
File "/home/web2py/gluon/tools.py", line 1167, in register
% dict(key=key)):
File "/home/web2py/gluon/tools.py", line 258, in send
payload['Subject'] = subject.decode(encoding).encode('utf-8')
AttributeError: 'lazyT' object has no attribute 'decode'
Maybe I'm making something wrong but, I check all my code and I can't
find why of this error.
Thank you for all your help!!!
Best Regards,
Victor.
--
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/web2py?hl=en.