Paul Childs wrote:
> I had the same troubles and then I found this...
> http://www.carcosa.net/jason/blog/computing/django/gotchas-2006-04-19
> You will notice some other goodies there too. :)

Jason McBrayer uses the following regexs in his urls.py file:

     (r'^accounts/login/', 'django.views.auth.login.login'),
     (r'^accounts/logout/', 'django.views.auth.login.logout'),

I am using

     (r'^accounts/login/$', 'django.contrib.auth.views.login'),

Note the $ symbol. I've tried it with and without the $. No difference.

Also note that he is using views.auth.login.login vs. 
contrib.auth.views.login, which is what the Authentication documents --

http://www.djangoproject.com/documentation/authentication/

use. I copied and pasted from them, in fact. When I use his regexs 
instead, I get the following error:

ViewDoesNotExist at /accounts/login/
Could not import django.views.auth.login. Error was: No module named 
auth.login

So I don't think his are correct for the current version I'm using. (I 
pulled it from SVN some two days ago.) And when I follow the path 
contrib/auth/, I do find a views.py file with a method called login, so 
I think that contrib.auth.views.login is correct.

Chas. Munat
Seattle

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django 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/django-users
-~----------~----~----~----~------~----~------~--~---

Reply via email to