Registering User choices
How the registration of users choices on cookies works on your site
When the cookie management widget closes, Axeptio will itself write a "technical" cookie.
This technical cookie is a JSON object (a data structure readable by explorers) that contains the vendors list. You can decode it in Javascript by using the JSON.parse function. It is composed of properties reusing the vendors names that you have configured in the Axeptio backoffice. So, if you checked Google Analytics, you will find in this object a property google_analytics , that will be defined as true or false, depending if the user agreed or not with the trigger of this vendor.
The object contains the token aswell, used to register consent and the date at which it was given.
By default, it is attached to current domain, and not secured. This means that if the consent collection is done on www.monsite.com, the user choices will not affect app.monsite.com.
If you want to allow the consent collection to all sub-domains, you will have to modify the script used to load Axeptio.
Here is an example of code used to load our widget
1
<script>
2
window.axeptioSettings = {
3
  clientId: "5c11ff5ce95cd64112feab79",
4
};
5
 
6
(function(d, s) {
7
  var t = d.getElementsByTagName(s)[0], e = d.createElement(s);
8
  e.async = true; e.src = "//static.axept.io/sdk.js";
9
  t.parentNode.insertBefore(e, t);
10
})(document, "script");
11
</script>
Copied!
To declare the domain where you want your user preferences cookie, you will juste have to add a new property to the object axeptioSettings :
1
window.axeptioSettings = {
2
  clientId: "5c11ff5ce95cd64112feab79",
3
userCookiesDomain: "axeptio.eu" // added line
4
};
Copied!
Once the code changed, the cookie registered in the explorer will be available for all sub-domains of axeptio.eu, for example : mail.axeptio.eu or admin.axeptio.eu
Last modified 7mo ago
Copy link