set web.config.debug=False

Jinu於 2011年8月8日星期一UTC+8下午6時34分40秒寫道:
>
> I have created session and successfully logged into session. Now I 
> want to write code to logout from session. I have done it with the 
> following code. 
>
> class signout: 
>         def GET(self): 
>                 session.loggedin = False 
>                 session.kill() 
>                 return render.logout() 
>
> But this code is not working for me. I got the following error. 
>
>   File "/home/jinesh/PROJECT/login.py", line 41, in GET 
>     session.kill() 
>   File "/usr/local/lib/python2.7/dist-packages/web.py-0.36-py2.7.egg/ 
> web/session.py", line 179, in kill 
>     del self.store[self.session_id] 
>   File "/usr/local/lib/python2.7/dist-packages/web.py-0.36-py2.7.egg/ 
> web/session.py", line 69, in __getattr__ 
>     return getattr(self._data, name) 
> AttributeError: 'ThreadedDict' object has no attribute 'session_id' 
>
> Is the above code enough to logout from a session ?

-- 
You received this message because you are subscribed to the Google Groups 
"web.py" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/webpy.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to