Case 1 : Create a new Axeptio checkbox
You want to save your registers in accordance with new reglementation but you want to keep your actual checkbox ? Here is how
If you want to create a new checkbox that was'nt already on your website
void 0 === window._axcb && (window._axcb = );
//The name of service is "processings" in the case of marketing consents or "contracts" in the case of contracts consents.
//identifier is the identifier of the checkbox you want to target, marketing consents or contracts consents.
//We'll see later where to find it
node: document.getElementById('TODO change to the ID of the target div'),
// Here you will manage the texts to inform the final user about the purpose of this checkbox
checkboxText: "I agree to receive the newsletter",
checkboxDetailsText: "know more"
To find the identifier, it is necessary to go to the service you want.
Example : For a marketing checkbox:
- 1.Go to marketing consents module
- 2.Choose the checkbox you want to parameter
- 3.You'll see the screen below
In your project URL, you'll find in blue the data-id of your project, then in red the token of your identifier.
Your project ID is linked with the SDK integration for cookies.
In some cases you'll want to make the consent on your checkbox mandatory for your form submission. It's the case for submission of newsletters forms. Here is how :
// Function to make the consent "required"
document.querySelector(#span-axeptio > div > label > input).setAttribute('required', 'required');