Silverstripe module for implementing a GDPR compliant service notice on a silverstripe based website.
from the klaro website:
Klaro is a simple and powerful open source consent management platform (CMP) that helps you to meet the requirements of the GDPR and to protect the privacy of your website visitors and users.
Simply put, klaro is an easy to use and easy to set up tool for GDPR compliant cookie and service management. As Silverstripe does not provide such a mechanism out of the box, klaro can help fill in the gap for sites and applications aimed at european audiences.
While there are some modules around which allow the integration of klaro in a silverstripe based project, most of them use a database-centered approach for managing cookies and services. At Syntro, we believe that this approach, while flexible, does not do justice to the complexity of the subject matter and, because of the editability (and especially removability) of services by the end user, can be dangerous. For this reason, we introduced our own module.
syntro/silverstripe-klaro
uses the
silverstripe configuration api
and the silverstripe requirements pattern
to manage services in an easy to learn way while giving the end user some control
about texts displayed in the notice and modal.
Give it a try, Feedback is always welcome!
To install this module, run the following command:
composer require syntro/silverstripe-klaro
If you just want to add a new service, add the script like so:
use Syntro\SilverstripeKlaro\KlaroRequirements;
// ...
KlaroRequirements::klaroJavascript('path/to/file.js', 'myservice');
In order to add this service to the notice, create a config like so:
Syntro\SilverstripeKlaro\Config:
klaro_purposes:
mypurpose:
title: My Purpose
description: This is my purpose
klaro_services:
myservice:
title: My Service
purposes: [ 'mypurpose' ]
After flushing, the modal will display myservice
and the script will only be
active if accepted by the user.
Please read the documentation for further information about how to customise klaro:
See CONTRIBUTION.md for mor info.