While I thoroughly agree with the above two, I'll go one step further
and say you should probably never put any code that sets admins
(superusers, or even straight access to django admin console) into
code whatsoever.

To help you out with a direct answer:

django has no difference between admin and regular user except a few
flags that grant the ability to login to admin (or edit it).  While
those flags arent the subject, what you're looking for is part of the
request.

"request.user" will allow access to any *basic* information (assuming
you're using the django.contrib.auth module) the author may have

"request.user.username" is the login name of the current user, and the
actual information you want for the author field (I do this for a
picture upload app for a local project)


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