<!--
var url='http://www.mature-enligne.com';

function aff_div(a) {
 if(document.getElementById(a).style.display=="none") { document.getElementById(a).style.display="block"; }
 else { document.getElementById(a).style.display="none"; }
}

function aff_div2(a) {
 if(document.getElementById(a).style.visibility=="hidden") { document.getElementById(a).style.visibility="visible"; }
 else { document.getElementById(a).style.visibility="hidden"; }
}

function change_src(id, src) {
  document.getElementById(id).src=src+'.jpg'
}

function ScanCookie(variable) {
  cook=document.cookie;
  variable+="=";
  place=cook.indexOf(variable,0);
  if(place <= -1) { return("0"); }
  else {
    end=cook.indexOf(";",place)
    if(end <= -1) { return(unescape(cook.substring(place+variable.length,cook.length))); }
    else { return(unescape(cook.substring(place+variable.length,end))); }
  }
}

function CreationCookie(nom, valeur, duree) {
  var dateExp=new Date();
  var aujourdhui=new Date();
  dateExp.setTime(aujourdhui.getTime()+duree);
  document.cookie=nom+'='+escape(valeur)+'; expires='+dateExp.toGMTString();
}

function AjouterFavoris() {
  if(navigator.appName!='Microsoft Internet Explorer') { window.sidebar.addPanel("Vidéos de mature", "http://www.mature-enligne.com/videos-mature-1.html", ""); }
  else { window.external.AddFavorite("Vidéos de mature", "http://www.mature-enligne.com/videos-mature-1.html"); }
}

function clic_simple(url) {
  popunder=window.open(url, "_blank", "toolbar=0,location=0,directories=0,status=0,scrollbars=1,resizable=1,copyhistory=0,menuBar=0,width=820,height=700");
  popunder.blur();
  window.focus();
}

function click() {
  if(ScanCookie("dejapopup")==0) {
    clic_simple("top.php");
    var la_duree=3600*1000;
    CreationCookie("dejapopup","oui", la_duree);
  }
}

function plan(id) {
  if(document.getElementById(id)) {
    ledoc=document.getElementById(id);
    if((ledoc.style.display=="block")||(ledoc.style.display=="")) {
      ledoc.style.display="none";
      document.getElementById("span_"+id).innerHTML="Afficher";
    }
    else {
      ledoc.style.display="block";
      document.getElementById("span_"+id).innerHTML="Masquer";
    }
  }
}

function out(username) { image=new Image(); image.src='toplist/index.php?a=out&u='+username; }

function change_html(id, code) {
  if(document.getElementById(id)) {
    document.getElementById(id).innerHTML=code;
  }
}

function change_demo(src, img) {
  img.src=src;
}

var changing_thumbs=new Array();
function changeThumb(index, i, num_thumbs, path, path2) {
  if(changing_thumbs[index])
  {
    hidden_image_id=(i+1) % num_thumbs;
    document.getElementById(index).src="images/"+path+","+i+path2+".jpg";
    document.getElementById(index).src="images/"+path+","+hidden_image_id+path2+".jpg";
    i=i % num_thumbs;
    i++;
    setTimeout("changeThumb('"+index+"',"+i+", "+num_thumbs+", '"+path+"', '"+path2+"')", 600);
  }
}    

function startThumbChange(index, num_thumbs, path, path2) {
  changing_thumbs[index]=true;
  changeThumb(index, 1, num_thumbs, path, path2);
}

function endThumbChange(index, path, path2) {
  changing_thumbs[index]=false;
  document.getElementById(index).src="images/"+path+",1"+path2+".jpg";
}

function file(fichier) {
  if(window.XMLHttpRequest) { xhr_object=new XMLHttpRequest(); } // FIREFOX
  else if(window.ActiveXObject) { xhr_object=new ActiveXObject("Microsoft.XMLHTTP"); } // IE
  else { return(false); }
  xhr_object.open("GET", fichier, false);
  xhr_object.send(null);
  if(xhr_object.readyState==4) { return(xhr_object.responseText); }
  else { return(false); }
}

function ajax(id, type, text) {
  if(texte=file(url+'/ajax.php?type='+type+'&id='+id+'&'+text)) { return(texte); }
}

function check() {
  var REG_MAIL = /^[\w-\.]{2,}@[\w-]{1,}\./;
  if(!REG_MAIL.test(document.cd_form.email.value)) {
  	alert("Votre adresse email doit être valable");
  	document.cd_form.email.focus();
  	return false;
  }
  else
  {
  	return true;
  	//window.open("https://secure.securitetotale.com/cb.php?module=guest_cbsys_preform&w=0&force_step1=1&action=step2&email="+document.email_form.email.value+"&id=14453&idp=1&mb&tracker=mature_form&synergie=h&param=&num_facturation=1&oldrf=pvaH_xxx&rf=&id_site=&id_produit=&langue=fr");
  }
}
-->