
var timerMove=null;function movePicture(Sens){Pas=10;Objet=document.getElementById("picture");if(parseInt(Objet.style.left)+(Pas*Sens)>0){clearTimeout(timerMove);}
else if(parseInt(Objet.style.left)+(Pas*Sens)<-(Objet.offsetWidth-document.getElementById("defile").offsetWidth)){clearTimeout(timerMove);}
else{Objet.style.left=(parseInt(Objet.style.left)+(Pas*Sens))+"px";}
timerMove=setTimeout("movePicture("+Sens+");",30);}
function activeMenu(id){for(i=0;i<=2;i++){$(".tabs").removeClass("selected");$("#div_menu"+id).css({display:"none"});}
$(".bt"+id).addClass="selected";$("#div_menu"+id).css({display:"block"});}
function showPlayer(id,flv,file,width,height){var vid=new SWFObject("http://tools.mateurfou.com/player/player.swf","player"+id,width,height,"8");vid.useExpressInstall("http://tools.mateurfou.com/player/expressinstall.swf");vid.addParam("allowscriptaccess","always");vid.addParam("allowfullscreen","true");vid.addParam("wmode","transparent");vid.addParam("flashvars","file="+flv+"&image="+file+"");vid.addVariable("width",width);vid.addVariable("height",height);vid.addVariable("bufferlength","1");vid.addVariable("displayheight",height);vid.addVariable("autostart","true");vid.addVariable("shownavigation","false");vid.addVariable("javascriptid","player"+id);vid.addVariable("enablejs","true");vid.addVariable("linkfromdisplay","true");vid.addVariable("linktarget","_self")
vid.addVariable("shuffle","false");vid.addVariable("repeat","list");vid.write("player_"+id);}
function disclaimer(){if(getCookie('checkAge')=="1")return;else{var body=$('body')[0];div=document.createElement("div");div.setAttribute("id","overlay");body.appendChild(div);div.className="overlay";div=document.createElement("div");div.setAttribute("id","disclaimer");div.className="disclaimer";body.appendChild(div);$("#disclaimer").html("<div class='disclaimerClose'><a href=\"javascript:closeDisclaimer();\"><img src='http://mateurfou.com/img/disclaimer_close.gif' width='94' heiht='48' alt='Fermer'></a></div><div class='disclaimerOpen'><a href=\"javascript:openDisclaimer();\"><img src='http://mateurfou.com/img/disclaimer_open.gif' width='94' heiht='48' alt='Entrer' title='Entrer'></a></div>");}
return false;}
function openDisclaimer(){setCookie("checkAge");var elm=document.getElementById("disclaimer");elm.parentNode.removeChild(elm);var elm=document.getElementById("overlay");elm.parentNode.removeChild(elm);}
function closeDisclaimer(){window.location.replace(url_exit);}
function validSuppr(theForm){var chaine="Supprimer définitive ?";return(confirm(chaine));}
function updatePromo(){if(typeof(msgPromo)!='undefined'){var rand=Math.floor(Math.random()*msgPromo.length);msg=msgPromo[rand];$("#contenuMsgPromo").html(msg+"&nbsp;<img src='http://leboncoinducul.com/img/fleche_animer.gif' width='29' height='7' alt='<' align='bottom'><span style='color:#FF0066;font-size:10px;margin:0;padding:0;'>Voir la vidéo en streaming</span></a>");timerMove=setTimeout("updatePromo()",5000);}}
function makePromo(){document.body.style.marginTop="21px";div=document.createElement("div");div.setAttribute("id","alerte");div.className="msgPromo";document.getElementsByTagName('body')[0].appendChild(div);$("#alerte").css({display:"block"});$('#alerte').html("<a href='javascript:closePromo();'><img class='msgPromoClose' src='http://leboncoinducul.com/img/close.gif' width='14' height='14'></a><span id='contenuMsgPromo'></span>");}
function closePromo(){document.body.style.marginTop="0px";$("#alerte").css({display:"none"});}
function addToFavorites(anchor){if(window.external){window.external.AddFavorite(anchor.getAttribute('href'),anchor.getAttribute('title'));}}
function popup(url,nom,h,l,scroll,top){var PosX=(screen.availWidth-h)/2;var PosY=(screen.availHeight-l)/2;if(top==1){PosX=1;PosY=1;}
var option="resizable=yes,location=no,menubar=no,scrollbars="+scroll+",status=no,directories=no,top="+PosY+",left="+PosX+",width="+h+",height="+l;win=window.open(url,nom,option);if(win.window.focus)win.window.focus();}
function popUpExterne(url){window.open(url,"Site porno","width=300, height=400, resizable=yes, scrollbars=yes");}
function setCookie(name,value,expires,path,domain,secure){if(expires==undefined){var expires=new Date();expires.setTime(expires.getTime()+(24*3600*1000));}
if(path==undefined)path="/";document.cookie=name+"="+escape(value)+
((expires)?"; expires="+expires.toGMTString():"")+
((path)?"; path="+path:"")+
((domain)?"; domain="+domain:"")+
((secure)?"; secure":"");}
function getCookie(name){var dc=document.cookie;var prefix=name+"=";var begin=dc.indexOf("; "+prefix);if(begin==-1){begin=dc.indexOf(prefix);if(begin!=0)return null;}
else{begin+=2;}
var end=document.cookie.indexOf(";",begin);if(end==-1){end=dc.length;}
return unescape(dc.substring(begin+prefix.length,end));}
function openDvdImg(url){var win=window.open(url,'popdvd',"top=140, left=140, width=380, height=520, scrollbars=1, resizable=1, toolbar=1, location=1, menubar=1, status=1, directories=1");if(window.focus){win.focus()};}
function fullscreen(url,id){if(id!=null)countClick(id);params='width='+screen.width;params+=', height='+screen.height;params+=', top=0, left=0';params+=', location=yes';params+=', resizable=yes';params+=', menubar=yes';params+=', toolbar=yes';params+=', scrollbars=yes';params+=', status=yes';newwin=window.open(url,'',params);if(window.focus){newwin.focus()};return false;}
$(document).ready(function(){$('a[href*=#body]').click(function(){$('html').animate({scrollTop:0},'slow');return false;})
$(".thumb").click(function(){if(getCookie('partenaire')==null&&url_pop_up!=undefined){var win=window.open(url_pop_up,'_blank',"top=140, left=140, width=700, height=500, scrollbars=1, resizable=1, toolbar=1, location=1, menubar=1, status=1, directories=1");win.blur();window.focus();setCookie('partenaire',1);return true;}})
makePromo();updatePromo();});