On Jun 17, 7:17 am, mdipierro <mdipie...@cs.depaul.edu> wrote:
> no

Shame.

I patch this manually in my extended Auth class, but it's extra work
to keep updating my extension to keep in-line with main.

Here is a patch to tools.py (also sent by mail):

--- gluon\tools.py.928  Sat Jun 13 20:47:24 2009
+++ gluon\tools.py      Wed Jun 17 07:35:54 2009
@@ -825,6 +825,19 @@
             else:
                 user[form.vars.id] = dict(registration_key='')
                 session.flash = self.messages.registration_successful
+                table_user = self.settings.table_user
+                if 'username' in table_user.fields:
+                    username = 'username'
+                else:
+                    username = 'email'
+                users = self.db(table_user[username] == form.vars
[username])\
+                    .select()
+                user = users[0]
+                user = Storage(table_user._filter_fields(user,
id=True))
+                session.auth = Storage(user=user,
last_visit=request.now,
+
expiration=self.settings.expiration)
+                self.user = user
+                session.flash = self.messages.logged_in
             if log:
                 self.log_event(log % form.vars)
             if onaccept:

F

> On Jun 16, 10:10 pm, Richard <richar...@gmail.com> wrote:
>
> > hello,
>
> > I came across an old T2 thread (http://groups.google.com/group/web2py/
> > browse_thread/thread/a4af19f213f5040e/df86352747060125) where Massimo
> > said he would add automatic login after registration to T2.
>
> > This is useful for simple registration forms with no email
> > authentication. Has this feature been implemented in the Auth tool?
>
> > thanks,
> > Richard
>
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"web2py Web Framework" group.
To post to this group, send email to web2py@googlegroups.com
To unsubscribe from this group, send email to 
web2py+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to