Loading in SPIP
The Sirdata CMP plugin for SPIP automatically inserts the CMP tag at the very beginning of the <head> of every public page of your website. It is compatible with SPIP 3.2 to 4.x.
2 methods are available: with the plugin or directly in your templates 👍
Method A - With the Sirdata CMP plugin (recommended)
1) Download the plugin
2) Install the plugin
Unzip the archive and upload the sirdatacmp folder into the plugins/ folder at the root of your SPIP website (via FTP/SFTP or your hosting provider's file manager). Create the plugins/ folder if it does not exist.
3) Enable the plugin
In the SPIP private area, go to Configuration → Manage plugins, Inactive tab, then click Enable next to "Sirdata CMP".

4) Configure your CMP
Click Configure next to the plugin (or go to Configuration → Sirdata CMP). This page is restricted to the website webmasters.

Fill in:
your Partner ID and Config ID, which you can find in your account. They are the two IDs in the tag URL:
https://choices.consentframework.com/js/pa/PARTNER_ID/c/CONFIG_ID/cmp;tick Enable Sirdata CMP on the public website, then click Save.

5) Add the link to re-surface the CMP
Your visitors must be able to revisit and change their choices at any time. The plugin provides a model that displays a link re-opening the CMP (window.Sddan.cmp.displayUI()):
in the text of an article, for instance your privacy policy:
<sirdatacmp|>or, with a custom text,<sirdatacmp|texte=Cookie settings>;in a template, for instance the footer
squelettes/inclure/footer.html:[(#MODELE{sirdatacmp, texte=Manage cookies})](optionalclassparameter for styling).

And that's it, your Sirdata CMP is deployed on your SPIP website!
Check the installation
Display the source code of a public page of your website: the https://cache.consentframework.com/js/pa/PARTNER_ID/c/CONFIG_ID/stub and https://choices.consentframework.com/js/pa/PARTNER_ID/c/CONFIG_ID/cmp scripts must appear at the very top of the <head>, before any other script: right after the <head> tag, or right after the <meta charset> tag if your <head> starts with it.
Good to know:
the tag is never added to the SPIP private area, nor to RSS feeds;
if the tag is already in your templates (method B), the plugin does not add it a second time;
disabling the plugin removes the tag; Actions → Uninstall also deletes its settings.
Method B - Directly in your templates
You can also copy / paste the Sirdata CMP tag into the <head> of your templates, as high as possible and before any other script.
With the SPIP default templates:
if the
squelettes/inclure/head.htmlfile does not exist, copysquelettes-dist/inclure/head.htmlinto thesquelettes/inclure/folder (create it if needed);paste the tag at the very top of this file;
empty the SPIP cache: Maintenance → Empty the cache.
And that's it, your Sirdata CMP is deployed on your SPIP website!
Mis à jour
Ce contenu vous a-t-il été utile ?
