	var adj;
	var timer;
	var p=new Array(10);
	var tailleLierre=270;
	var ie=document.all?1:0;
	var opera=(navigator.userAgent.indexOf('Opera') != -1)
	var hauteurFrame;
	var offsetMenu=50;
	var y;
	var cible;
	p[1]='6';
	p[2]='14';
	p[3]='4';
	p[4]='5';
	p[5]='11';
	p[6]='8';
	p[7]='12';
	p[8]='9';

	function slideshow()
		{
		var n=1+Math.floor(Math.random()*8);
		var url="images/p"+p[n]+".jpg";
		document.getElementById("photo").src=url;
		timer1=setTimeout('slideshow()',2000);
		}
		
	function showSprite(obj)
	{
		obj.style.visibility="visible";
	}
	
	function hideSprite(obj)
	{
		obj.style.visibility="hidden";
	}
		
	function affiche_diapo(nom)
	{
		var fond=document.getElementById("fenetre_photos");
		var diapo=document.getElementById("photos_" + nom);
		if(fond != null && diapo != null)
		{
			showSprite(fond);
			showSprite(diapo);
		}
	}
		
	function deplace()
		{
		var fleche=document.getElementById("fleche");
		var corde=document.getElementById("corde");

		var etat=false;
		var t=parseInt(fleche.style.top);

		if (y > t )
			{
				t=t+10;
				etat=true;
			}
		if (y < t )
			{
				t=t-10;
				etat=true;
			};
			
		if (etat) 
			{	
				fleche.style.top=t+"px";
				corde.style.height=t+"px";
				timer=setTimeout ('deplace()',50);
			}
		else
			window.location= cible + '.php';
		}
	function pointe(n)
		{
		switch (n)
			{
			case 1:
				y=110;
				cible='index';
				break;
			case 2:
				y=190;
				cible='chambres-hotes';
				break;
			case 3:
				y=270;
				cible='gites';
				break;
			case 4:
				y=350;
				cible='aude';
				break;
			case 5:
				y=430;
				cible='contact';
				break;
			}
		clearTimeout(timer);
		deplace();	
		};
