//img aleatoire entraineurs
var nbimage= 20;
var width;
var height;
var url;
var alte;
function ban()
{
numimage= Math.round(Math.random()*(nbimage-1)+1);
if (numimage <= 10)
{
gotosite = "";
url = "http://paysagisteideeconcept.com/img/general/excavation.jpg";
alte = "";
TARGET="_blank";
}
if (numimage > 10)
{
gotosite = "";
url = "http://paysagisteideeconcept.com/img/general/341-2.gif";
alte = "";
TARGET="_self";
}
if(gotosite != "")
	{
	document.write ('<A HREF="' + gotosite + '">');	
	}
document.write('<IMG SRC="' + url + '" ALT="' + alte + '" BORDER=0>')
if(gotosite != "")
	{
	document.write('</A>')
	}
}

//DEFILEMENT IMAGES LIENS
imgPath = new Array;
SiClickGoTo = new Array;
if (document.images) 
{
	i0 = new Image;
	i0.src = 'img/fourn/appq.gif';
	SiClickGoTo[0] = "http://www.appq.org/html/page_d_accueil.html";
	imgPath[0] = i0.src;
	
	i1 = new Image;
	i1.src = 'img/fourn/compost.gif';
	SiClickGoTo[1] = "http://www.composts.com/fr/frameset.html";
	imgPath[1] = i1.src;
	
	i2 = new Image;
	i2.src = 'img/fourn/perm.gif';
	SiClickGoTo[2] = "http://www.permacon.ca/skins/default/index.html";
	imgPath[2] = i2.src;
	
	i3 = new Image;
	i3.src = 'img/fourn/tp.gif';
	SiClickGoTo[3] = "http://www.transpave.com";
	imgPath[3] = i3.src;
}
a=0;

function ejs_img_fx(img) {
	if(img && img.filters && img.filters[0]) {
		img.filters[0].apply();
		img.filters[0].play();
	}
}

function StartImgAnim() 
{
	if (document.images) 
	{
		document.write('<a href="#" onclick="ImgDest(); return false;"><img src="img/def_ini.gif" border="0" alt="" name="defil" style="filter:progid:DXImageTransform.Microsoft.Pixelate(MaxSquare=100,Duration=1)" /></a>');
		defilimg()
	} 

}

function ImgDest() 
{
	window.open(SiClickGoTo[a],'_blank');
}


function defilimg() 
{
	if (document.images) 
	{
		a = Math.round(Math.random()*(3));
		ejs_img_fx(document.defil)
		document.defil.src = imgPath[a];
		tempo1 = setTimeout("defilimg()",5000);
	}
}






//user-p
var win=null;
function openfenetre(mypage,myname,w,h,scroll,pos)
{
  if(pos=="random"){LeftPosition=(screen.width)?Math.floor(Math.random()*(screen.width-w)):100;TopPosition=(screen.height)?Math.floor(Math.random()*((screen.height-h)-75)):100;}
  if(pos=="center"){LeftPosition=(screen.width)?(screen.width-w)/2:100;TopPosition=(screen.height)?(screen.height-h)/2:100;}
  else if((pos!="center" && pos!="random") || pos==null){LeftPosition=0;TopPosition=20}
  settings='width='+w+',height='+h+',top='+TopPosition+',left='+LeftPosition+',scrollbars=0,location=no,directories=no,status=no,menubar=no,toolbar=no,resizable=no';
  win=window.open(mypage,myname,settings);
}