Variations of this question have been asked, but I\'m still unable to get my stylesheets to load correctly when my templates are rendered.
I\'m attempting to serve s
I just had to figure this out myself.
settings.py:
MEDIA_ROOT = 'C:/Server/Projects/project_name/static/'
MEDIA_URL = '/static/'
ADMIN_MEDIA_PREFIX = '/media/'
urls.py:
from django.conf import settings
...
if settings.DEBUG:
urlpatterns += patterns('',
(r'^static/(?P.*)$', 'django.views.static.serve', {'document_root': settings.MEDIA_ROOT}),
)
template file:
With the file located here:
"C:/Server/Projects/project_name/static/css/style.css"