1
0
mirror of https://github.com/r4sas/py-i2phosts synced 2025-01-08 22:07:55 +00:00

pyi2phosts/urls.py: allow django to serve static files when debug enabled

This commit is contained in:
Hidden Z 2010-11-05 11:57:47 +00:00
parent e8d0c8b07a
commit 2e5ba8d88d

View File

@ -20,3 +20,7 @@ urlpatterns = patterns('',
# Uncomment the next line to enable the admin:
(r'^admin/', include(admin.site.urls)),
)
if settings.DEBUG:
urlpatterns += patterns('', (r'static/(?P<path>.*)$', 'django.views.static.serve',
{'document_root': settings.MEDIA_ROOT, 'show_indexes':True}))