I've always done it as rebus_ explained.  Put the login options in the
base template wrapping it in {% if user.is_authenticated %} to display
a different mechanism for users that are already logged-in.  That form
action is set to the login URL and and the login view handles the
login processing, error handling, and redirects.

On Feb 21, 11:44 am, Patrick <pstei...@gmail.com> wrote:
> I thought that if I put the login forms on the base template and then
> extend all others from that base template, the login forms would be
> available all the way through. But there is a problem: the login forms
> are only displayed if the url is processed by the 'login' view. That
> login view provides the forms needed for authentication, among other
> things.
>
> The thing is, what I want is to allow user to authenticate no matter
> what page from the site he is visitting. How can that be done?
>
> Many thanks in advance,
>
> Patrick Steiger

-- 
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.

Reply via email to