function popupContact(a,b,c,d,e,f) {
	window.open('show_contact.html?id='+d+a+f+b+'&type='+c+'&lang='+e,'', 'top=50, left=50, width=750, height=580, resizable=yes, toolbar=no, scrollbars=yes, status=no');
}

function popupRatingAd(src, id) {
	window.open(src+'?id='+id, '', 'top=250, left=250, width=600, height=260, resizable=yes, toolbar=no, scrollbars=non, status=no, directories=no');
}

function popupRatingUser(src, user_id) {
	window.open(src+'?user_id='+user_id, '', 'top=250, left=250, width=600, height=260, resizable=yes, toolbar=no, scrollbars=non, status=no, directories=no');
}

function popupSmileys (src) {
	window.open(src,'', 'top=20, left=20, width=220, height=360, resizable=yes, toolbar=no, scrollbars=yes, status=yes');
}

function popupMessage (src) {
	window.open(src,'', 'top=20, left=20, width=600, height=445, resizable=yes, toolbar=no, scrollbars=yes, status=yes');
}

function popupSupprimer (src) {
	window.open(src,'', 'top=20, left=20, width=740, height=400, resizable=yes, toolbar=no, scrollbars=yes, status=yes');
}

function popupEditer (src) {
	window.open(src,'', 'top=20, left=20, width=740, height=400, resizable=yes, toolbar=no, scrollbars=yes, status=yes');
}

function popupAbus (src) {
	window.open(src,'', 'top=20, left=20, width=740, height=450, resizable=yes, toolbar=no, scrollbars=yes, status=yes');
}

function go2url(sel, targetstr)
{
  var index = sel.selectedIndex;
  if (sel.options[index].value != '') {
     if (targetstr == 'blank') {
       window.open(sel.options[index].value, 'win1');
     } else {
       var frameobj;
       if (targetstr == '') targetstr = 'self';
       if ((frameobj = eval(targetstr)) != null)
         frameobj.location = sel.options[index].value;
     }
  }
}

function show_list(value)
{
	var choix = document.getElementById("origin");

	if(choix.value == value)
	{
		document.getElementById("list").style.display = "block";
	}
	else
	{
		document.getElementById("list").style.display = "none";
	}
}

function show_list_newsletter(Controleur, Controle, Masquer)
{
	var objControleur = document.getElementById(Controleur);
	var objControle = document.getElementById(Controle);
	if (Masquer=='1')
		objControle.style.visibility=(objControleur.checked==true)?'visible':'hidden';
	else
		objControle.disabled=(objControleur.checked==true)?false:true;
	return true;
}

function MM_swapImgRestore()
{ //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_findObj(n, d)
{ //v4.01
	var p,i,x;
	if(!d)
		d=document;
	if((p=n.indexOf("?"))>0&&parent.frames.length)
	{
		d=parent.frames[n.substring(p+1)].document;
		n=n.substring(0,p);
	}
	if(!(x=d[n])&&d.all) x=d.all[n];
	for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
		for(i=0;!x&&d.layers&&i<d.layers.length;i++)
			x=MM_findObj(n,d.layers[i].document);
	if(!x && d.getElementById)
		x=d.getElementById(n);
	return x;
}

function MM_swapImage()
{ //v3.0
	var i,j=0,x,a=MM_swapImage.arguments;
	document.MM_sr=new Array;
	for(i=0;i<(a.length-2);i+=3)
		if ((x=MM_findObj(a[i]))!=null)
		{
			document.MM_sr[j++]=x;
			if(!x.oSrc) x.oSrc=x.src;
			x.src=a[i+2];
		}
}

function MM_openBrWindow(theURL,winName,features)
{ //v2.0
  window.open(theURL,winName,features);
}

function pubOrganized()
{
	var scraper = document.getElementById("global_sky");
	if(scraper){
		var scrollY = 0;
		var bodyheight=0;
		if(document.documentElement && document.documentElement.scrollTop)
		{
			scrollY = document.documentElement.scrollTop;
			bodyheight=document.documentElement.scrollHeight;
		}
		else if(document.body && document.body.scrollTop)
		{
			scrollY = document.body.scrollTop;
			bodyheight=document.body.scrollHeight;
		}
		else if(window.pageYOffset)
		{
			scrollY = window.pageYOffset;
		}
		else if(window.scrollY) {
			scrollY = window.scrollY;
		}
		scrollY=scrollY-68;
		if(scrollY<0){
			scrollY = 0;
		}
		else if(bodyheight>0 && scrollY>bodyheight-755){
			scrollY = bodyheight-755;
		}
		else if(scrollY>10000){
			scrollY=10000;
		}
		scraper.style.top = scrollY + "px";
		setTimeout('pubOrganized()',20);
    }
}
