Hello all,
I've pretty quikly found out in my DJango adventure that I need to have
some kind of versioning for my static css and javascript files. After
talking to some web developers I was directed to use Django's
CachedStaticFilesStorage app to append an md5 hash to the static files
path. No matter how I set my static settings the files don't seem to get
the has appended and I can no longer link to any of my static files,
either directly or using the static directive. I was wondering if anyone
might know what I am doing wrong.
My Settings:
STATIC_ROOT = 'staticfiles'
STATIC_URL = ''
# Additional locations of static files
STATICFILES_DIRS = ()
STATICFILES_FINDERS = (
'django.contrib.staticfiles.finders.FileSystemFinder',
'django.contrib.staticfiles.finders.AppDirectoriesFinder',)
STATICFILES_STORAGE =
'django.contrib.staticfiles.storage.CachedStaticFilesStorage'
My Template entry:
{% block cssfiles %}{% load static%}<link href="{% static "/static/css/map.css"
%}" media="screen">{% endblock %}
Anything that can point me in the right direction would help.If intrested, I've
also had this question up on StackOverflow for a few days:
http://stackoverflow.com/questions/22130697/djangos-cachedstaticfilesstorage-not-hashing-file-urls
--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-users/4ee50ecb-4f5b-4e6d-a683-d0c7bd7a979d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.