Django plugin to add and configure the Cookie Control by Civic UK
Project description
django-cookie-control
A Django plugin to integrate the Civic UK Cookie Control (https://www.civicuk.com/cookie-control)
The plugin is compatible with Django, DjangoCMS and Django/CMS multisite.
To install
Install the application via pip:
pip install django-cookie-control
Add 'django_cookie_control' to installed apps:
INSTALLED_APPS = [ ... 'django_cookie_control', ...]
Add/Edit the following to settings.py
if required with required cookies:
# DEFAULT if missing:
COOKIE_CONTROL_REQUIRED_COOKIES = ['csrftoken','django_language','sessionid','django_privacy_mgmt_preferences','AWSALB']
Run or make migrations:
python.exe manage.py migrate
To configure
For a full list of configuration settings see the Civic UK site, here:
https://www.civicuk.com/cookie-control/v8/documentation
Plugin configuration overview:
- Add a new configuration - custom configuration for different sites via multisite.
- Configure Main Settings
- Site name
- API key
- Cookie Control product version: Community, Pro, Pro Multisite
- Display Options
- Position
- Theme style
- Toggle type
- Close style
- Text and Accessibility
- Custom Settings
- Pro and Pro_Multisite Settings A series of settings for the paid Pro plugins, including:
- Custom text
- Custom formatting
- Cookies
- Necessary Cookies
- A simple list of cookie names, including wildcards that are necessary for the site
- A default list for Django, DjangoCMS, and AWS are already included.
- Optional Cookies
- Add an optional cookie or package of cookies that can be turned off for the site
- Using separate functions On Accept or for On Revoke the cookies can be customised to be disable or enabled.
To Test
Use IE11's emulation to test this tool -
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
Hashes for django_cookie_control-1.1.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | ea55bb5a1a4d9605e99c0da0b3376c3d083cb5876d1e83a7215a4b14c5eef210 |
|
MD5 | 2b1df04edb0f884a519d630333cf0bc9 |
|
BLAKE2b-256 | cce8c3e4af8d8e6b66fbd25af6a66ba98c7bf473bb591eb25115fde539aeb557 |
Hashes for django_cookie_control-1.1.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | da7fd885c64f12f5e7ca3f85ad64ad2c69a06413bd21b6fd466e548ab69005a8 |
|
MD5 | 4dc90879a2478220fa40132438738978 |
|
BLAKE2b-256 | 8788c5e2c8488b0ef7b585e3c32745023ea169c068292854f82415e6e2e2836f |