
function AffCook() {
        Aff=window.open('','Cook','width=600,height=200,scrollbars=yes,resizable=yes');

        with (Aff.document) {
                close();
                open();
                writeln('<html><body>');
                writeln('<font face="Arial,Helvetica" size=4><b><center>');
                writeln('Cookies : </center></b></font><pre>');
                var Cook = document.cookie;
                  var i = 1;
                  while ((Ret = GetField(Cook,i,"; ")) != null) {
                                write("<b>" + unescape(GetField(Ret,1,"=")) + " :</b>");
                                writeln(unescape(GetField(Ret,2,"=")));
                        i++;
                }
                writeln('<pre>');
                close();
        }
}

function GetCookie (name) {
        var arg = name + "=";
            var Cook = document.cookie;
          var i = 1;
          while ((Ret = GetField(Cook,i,"; ")) != null) {
                        if (Ret.substring(0,arg.length) == arg)
                                return unescape(GetField(Ret,2,"="));
                        i++;
                }
          return null;
   }
function GetField(Chaine,Nombre, Sep) {
        if (Sep == null) Sep = ";";
        var Compteur = 0;
        var x = 0;
        var Param = "";
        while (Chaine != null) {
                Compteur += 1;
                x=Chaine.indexOf(Sep);
                if (x == -1) {
                        Param = Chaine;
                        Chaine = null;
                } else {
                        Param = Chaine.substring(0,x);
                        Chaine = Chaine.substring(x+Sep.length , Chaine.length);
                }
                if (Compteur == Nombre) {
                        return (Param);
                }
        }
        return (null);
}
function MultiMania() {
        madate = new Date(2020,1,1);
        Exp = madate.toGMTString();
        document.cookie="AdID=" + GetCookie("AdID") + "; path=/; domain=.multimania.com; expires=" + Exp
	}

function Publicite() {
        madate = new Date(1998,1,1);
        Exp = madate.toGMTString();
        document.cookie="AdID=; path=/; domain=.multimania.com; expires=" + Exp
        location.reload(true);
}

