Advertisement
Guest User

Untitled

a guest
Sep 21st, 2017
61
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.51 KB | None | 0 0
  1. Dir structure (simplified):
  2. app1/static/js/file.js
  3. app1/static/css/file.css
  4. app2/static/js/otherfile.js
  5. app2/static/css/otherfile.css
  6. templates/template.html
  7.  
  8. Template.html:
  9. <script src="{{ STATIC_URL }}js/file.js"></script>
  10.  
  11. Project Root
  12. Settings file
  13. Manage.py file
  14.  
  15. STATICFILES_DIRS = (
  16. # ...
  17. ("resources", "C:/data/django/myproject/myapp/static"), )
  18.  
  19. <link rel="stylesheet" href="{%static 'resources/favicon.png' %}" type="text/css">
  20.  
  21. {% static "js/lib/jquery-1.8.2.min.js" %}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement