August 2016
Beginner to intermediate
717 pages
15h 24m
English
If you set STATIC_URL to a static value, then each time you update a CSS file, JavaScript file, or image, you will need to clear the browser cache in order to see the changes. There is a trick to work around clearing the browser's cache. It is to have the revision number of the version control system shown in STATIC_URL. Whenever the code is updated, the visitor's browser will force the loading of all-new static files.
This recipe shows how to put a revision number in STATIC_URL for subversion users.
Make sure that your project is under the subversion version control and you have BASE_DIR defined in your settings, as shown in the Defining relative paths in the settings recipe.
Read now
Unlock full access