I would do per request url routing: 
http://www.b-list.org/weblog/2007/nov/06/urlconf/

On Apr 13, 9:17 pm, "Cole Tuininga" <[EMAIL PROTECTED]> wrote:
> Hey folks -
>
> I'm looking to make url "routing" choices based on some values from
> the session.  That is, I want to change the url->view mapping based on
> the session variables.  Problem is, I can't seem to figure out how to
> access the session from urls.py.  I understand that outside views I
> can load up a session object by importing
> django.contrib.sessions.models.Session and then doing a get by using a
> pk of the session id.  But since I don't know how to access the
> request object from within urls.py, I don't know how to get the cookie
> value containing the session id.  :)  And if I could access the
> request object, I wouldn't need to go through that rigamarole, since
> I'd be able to just access request.session directly.
>
> Help?  (I'm using Django 0.96.1, btw)
>
> Many thanks!
>
> --
> Cole Tuiningahttp://www.tuininga.org/
--~--~---------~--~----~------------~-------~--~----~
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