Created
March 16, 2013 19:53
-
-
Save julianwachholz/5178024 to your computer and use it in GitHub Desktop.
Conditional urls?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
if settings.DEBUG: | |
urlpatterns += patterns( | |
'', | |
url(r'^media/(?P<path>.*)$', 'django.views.static.serve', { | |
'document_root': settings.MEDIA_ROOT, | |
}), | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment