~widelands-dev/widelands-website/django_staticfiles

« back to all changes in this revision

Viewing changes to local_urls.py.sample

  • Committer: franku
  • Date: 2018-11-21 08:34:18 UTC
  • Revision ID: somal@arcor.de-20181121083418-p99s2btfg0913st3
adapted to django default static file handling

Show diffs side-by-side

added added

removed removed

Lines of Context:
6
6
# Don't use this file on the server!
7
7
 
8
8
local_urlpatterns = [
 
9
   # wl specific static files (css, js) and user media (images, maps)   
9
10
   url(r'^wlmedia/(?P<path>.*)$',
10
11
       serve,
11
12
       {'document_root': settings.STATIC_MEDIA_PATH},
12
13
       name='static_media'),
13
 
   url(r'^media/(?P<path>.*)$',
 
14
   # Static files from third party apps.
 
15
   url(r'^static/(?P<path>.*)$',
14
16
       serve,
15
 
       {'document_root': settings.STATIC_MEDIA_PATH},
16
 
       name='static_media_pybb'),
 
17
       {'document_root': settings.STATIC_ROOT},
 
18
       name='static_media_foreign'),
 
19
   # HTML documentation created by ./manage.py create_docs
17
20
   url(r'^documentation/(?P<path>.*)$',
18
21
       serve,
19
 
       {'document_root': path.join(settings.STATIC_MEDIA_PATH, 'documentation/html')},
20
 
       name='documentation'),
 
22
       {'document_root': path.join(
 
23
         settings.STATIC_MEDIA_PATH, 'documentation/html')},
 
24
       name='documentation')
21
25
]
 
26