Provides a very simple tag to load settings variables from Django templates
Project description
Provides a very simple tag to load settings variables from Django templates. If the variable doesn’t exists, an empty string is returned.
Install
To install / update the module:
pip install django-custom-settings-templatetag -U
Usage
In your Django tempalte, do the following :
{% load custom_settings %}
{% settings_value "CUSTOM_VAR_IN_SETTINGS" as CUSTOM_VAR %}
{% if CUSTOM_VAR %}
var={{ CUSTOM_VAR }}
{% endif %}
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for django-custom-settings-templatetag-1.0.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4f4a976b09f8fa0b030d7f807b1a9c440ce1f9101ac5fb6bcc1efaabd26514eb |
|
MD5 | 28f11e71b79f86010e3bd996f35a9ee0 |
|
BLAKE2b-256 | bf2306c917d52b314a4677f4add492bfeba41bc14dbbfd327bc43268da430373 |
Close
Hashes for django_custom_settings_templatetag-1.0.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | bd834f1883eef4c5d3da7e4743da77ea3ee46cab00364d3177cb6c1a44d3cfe5 |
|
MD5 | cd9e486c8f38a28814817184570fd5a0 |
|
BLAKE2b-256 | e9a7d21942884d7848ad95f27f7ee264ea7d31b7f3a8969773122bf9f74e54fe |