Victor Loureiro Lima wrote:. > auth system is in fact invalidating my current session id cookie, but > afterwards it sets a new session id cookie, why does it do that? >
Um. So that anonymous users of your site still have sessions? Django supports "anonymous sessions", sessions and auth are different. > Basically on my systems, I want to differentiate user in two groups: > Anonymous ( ones that doesnt have a valid session id cookie ), logged ones ( > ones that have a valid session id cookie ). That's just not the way that distinction is made. Seeing as sessions may be anonymous and all. For your code, note that if request.user is a logged in User, .is_authenticated() will be True and .is_anonymous() will be False. OTO, if request.user is an AnonymousUser, .is_anonymous() will be True and is_authenticated() will be False. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@googlegroups.com. To unsubscribe from this group, send email to django-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-users?hl=en.