Electronics & Programming


Open Source electronics development and programming

  • You are not logged in.

#1 Dec. 19, 2010 01:41:11

Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

Location based site

I have a django based web site. The current url is something likehttp://www.mysite.com/catalog/xxx.
Now I want to customize the store based on customer location, so the
url will look someting likehttp://www.mysite.com/chicago/catalog/xxx.
I can use
urlpatterns = patterns('',
(r'^(?P<city>\w+)/', include('store.urls')),
to parse the city string and send it to the view function. However,
the problem is that I have to modify all the current view functions to
handle the new <city> argument. Is there a way to customize the view/
template without rewriting all the view functions again?


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
For more options, visit this group athttp://groups.google.com/group/django-users?hl=en.


Board footer

Moderator control

Enjoy the 23rd of March

The Forums are managed by develissimo stuff members, if you find any issues or misplaced content please help us to fix it. Thank you! Tell us via Contact Options
Leave a Message
Welcome to Develissimo Live Support