Template context processor to make the settings.py values available in templates

1
2
3
4
from django.conf import settings                                                                                             
                                                                                                                             
def access_to_settings(request):
    return {'SETTINGS' : settings}

More like this

  1. Add site info to request context by bthomas 4 years, 6 months ago
  2. Add URL Segments to Templates by epicserve 4 years, 7 months ago
  3. media_url context variable by marchino 6 years, 1 month ago
  4. Flash Message Template Tag by rtconner 5 years, 10 months ago
  5. Quickly check templates while sketching them out by Amr Mostafa 6 years, 1 month ago

Comments

(Forgotten your password?)