I have been trying to delete the demdex cookie using a JS function and I am not able to delete it. The same JS function deletes other cookies but it won't delete the demdex cookie. Please see the function below:
function deleteCookies(cookieNames) {
for (var i = 0; i < cookieNames.length; i++) {
document.cookie = cookieNames[i] + '=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/;domain=.demdex.net';
}
}
var cookiesToDelete = ['demdex'];
deleteCookies(cookiesToDelete);
Is there anything wrong with this function? And is there another way to do it?
Also, is the demdex cookie always fire along with the AMCV and AMCVS cookie?
Solved! Go to Solution.
Topics help categorize Community content and increase your ability to discover relevant content.
Views
Replies
Total Likes
What you're experiencing is correct behaviour. demdex.net cookies are considered as third-party cookies relative to your website's domain. All web browsers have a data security feature to prevent one domain from accessing cookies belonging to another domain. That's why your script is not able to find nor delete the demdex.net cookies, because your script is running from your website's domain.
What demdex.net does is that its script calls a URL from demdex.net, and that demdex.net URL response has code that sets the cookie within the demdex.net domain.
I know of others who have tried to delete demdex.net cookies (because of GDPR or other data privacy regulations), but have been unsuccessful. I suggest that you bring this up with Customer Care so that they can get the relevant Adobe engineers to seriously consider such a cookie deletion feature for demdex.net.
Views
Replies
Total Likes
What you're experiencing is correct behaviour. demdex.net cookies are considered as third-party cookies relative to your website's domain. All web browsers have a data security feature to prevent one domain from accessing cookies belonging to another domain. That's why your script is not able to find nor delete the demdex.net cookies, because your script is running from your website's domain.
What demdex.net does is that its script calls a URL from demdex.net, and that demdex.net URL response has code that sets the cookie within the demdex.net domain.
I know of others who have tried to delete demdex.net cookies (because of GDPR or other data privacy regulations), but have been unsuccessful. I suggest that you bring this up with Customer Care so that they can get the relevant Adobe engineers to seriously consider such a cookie deletion feature for demdex.net.
Views
Replies
Total Likes
Thank you @yuhuisg! This is a very helpful answer. Let me take it up with the adobe team. Thank you!
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies
Views
Likes
Replies