Url overrides and concurrent site versions

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
# in the project urls_staging.py
urlpatterns = patterns('',
    (r'^about/', include('live.about.urls_staging')),
    (r'^about/', include('live.about.urls')),
    (r'^places/', include('live.place.urls.places_staging')),
    (r'^places/', include('live.place.urls.places')),
    (r'^comments/', include('live.place.urls.comments_staging')),
    (r'^comments/', include('live.place.urls.comments')),

    (r'^users/', include('live.users.urls_staging')),
    (r'^users/', include('live.users.urls')),

    (r'^admin/', include('django.contrib.admin.urls')),
)

# in the app urls_staging.py
from django.conf.urls.defaults import *
urlpatterns = patterns('live.users.views.account',
    (r'^account$', 'my_account'),
    (r'^account/friends$', 'friends'),
)

More like this

  1. Ajax progress bar by ebartels 5 years, 1 month ago
  2. Mobilize your Django site by stevena0 4 years, 1 month ago
  3. testdata tag for templates by showell 4 years ago
  4. Use django-social-auth & Google Accounts for admin login by pmdarrow 5 months, 2 weeks ago
  5. Run a testcase with custom INSTALLED_APPS by vdboor 6 months, 2 weeks ago

Comments

(Forgotten your password?)