Hi all,

Let's assume you have a *global* login form in the base_template.html
of a blog like application. How would you handle validation of such a
form?

The form would need to be passed to every view and every view should
be made aware of it's validation checking for form.is_valid()

Typical use-case:
A user is reading an article and he's required to login to post a
comment. Without leaving the article's page he inserts username and
password in the login form above the article.

I ended up modifying the workflow but how would you handle my original
scenario?

I kinda hit the same wall when trying to implement my home-grown per-
object-permission system as i added a check on every view to verify
that the current logged-in user was the owner of the records he was
trying to view/modify.


Thanks,
Lorenzo
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to