1

I need to remove cookies (EU cookie law).

I have an old openX server installed and ads are displayed trough JS invocation code. Since we don't need to count ad display per user, I'd like to remove OAID cookie completely.

var m3_u = (location.protocol=='https:'?'https://ads.domain.com/www/delivery/ajs.php':'http://ads.domain.com/www/delivery/ajs.php');

I've tried adding setcookie ("OAID", "", time() - 3600); to the end of ajs.php but cookies are still set. Could someone give me a pointer where to disable or remove cookies?

Tunaki
  • 132,869
  • 46
  • 340
  • 423
Miha Trtnik
  • 236
  • 1
  • 3
  • 8

1 Answers1

0

The browser does not provide a way to remove a cookie other than to turn it into a session cookie by setting a expiry date in the past. The cookies are deleted at the end of the session but according to most interperatations that would still count as an infringement. You are probably going to have to edit or replace the openX server, or not display ads until the user has accepted the cookies.

user1937198
  • 4,987
  • 4
  • 20
  • 31
  • Thanks. Not displaying ads is not an option. Even with the code above cookie is still set and expiration date is one year. So basically cookie has to be set after the line I've put setcookie on. – Miha Trtnik Jun 17 '13 at 17:00
  • Set cookie has to be called during the header section of the php but after the ads server sets the cookie – user1937198 Jun 17 '13 at 17:16