<!--
//alors ça y est on a le source de la bibliothèque de fonctions.
//Mais est-ce ici que se trouve le code de désactivation du click de droite ?
//petit rappel quand on l'a trouvé, on le maile à : yves-roque@informaticien.net
function getl()
{w=parent.top.window
x=w.language();
return x;
}
function itext(fr,gb)
{
if (getl()=='francais')
  {document.write(fr);}
else
  {document.write(gb);}
}

function GetCookie (name) {  
	var arg = name + "=";  
	var alen = arg.length;  
	var clen = document.cookie.length;  
	var i = 0;  
	while (i < clen) {    
	var j = i + alen;    
	if (document.cookie.substring(i, j) == arg)      
		return getCookieVal (j);    
		i = document.cookie.indexOf(" ", i) + 1;    
		if (i == 0) break;   
	}  
	return null;
}
function SetCookie (name, value) {  
	var argv = SetCookie.arguments;  
	var argc = SetCookie.arguments.length;  
	var expires = (argc > 2) ? argv[2] : null;  
	var path = (argc > 3) ? argv[3] : null;  
	var domain = (argc > 4) ? argv[4] : null;  
	var secure = (argc > 5) ? argv[5] : false;  
	document.cookie = name + "=" + escape (value) + 
	((expires == null) ? "" : ("; expires=" + expires.toGMTString())) + 
	((path == null) ? "" : ("; path=" + path)) +  
	((domain == null) ? "" : ("; domain=" + domain)) +    
	((secure == true) ? "; secure" : "");
}
function DeleteCookie (name) {  
	var exp = new Date();  
	exp.setTime (exp.getTime() - 1);  
	// This cookie is history  
	var cval = GetCookie (name);  
	document.cookie = name + "=" + cval + "; expires=" + exp.toGMTString();
}
var expDays = 30;
var exp = new Date();
var mncda='Menu contextuel désactivé'
exp.setTime(exp.getTime() + (expDays*24*60*60*1000));
function amt(){
	var count = GetCookie('Presence')
	if(count == null) {
		SetCookie('Presence','1')
		return 1
	}
	else {
		var newcount = parseInt(count) + 1;
		DeleteCookie('Presence')
		SetCookie('Presence',newcount,exp)
		return count
	}
}

function mousedownhdn(click_button)
 	{if(document.layers)  {if (click_button.which==3) {alert(mncda);return false;}}
  	 if(document.all)     {if(event.button==2)  {alert(mncda);return false;}}
  	 if(oldhandler!=null)
       {alert(oldhandler);
        oldhandler(click_button);
       }
  };
 var oldhandler=null;
 function sethdn()
  {if(document.onmousedown!=mousedownhdn) 
      {oldhandler=document.onmousedown;
        document.onmousedown = mousedownhdn;
        if(document.layers) {document.captureEvents(Event.MOUSEDOWN);}
      }
//    setTimeout('sethdn()',100);
   }

sethdn();

function getCookieVal(offset) {
  var endstr = document.cookie.indexOf (";", offset);
  if (endstr == -1)
    endstr = document.cookie.length;
  return unescape(document.cookie.substring(offset, endstr));
}


function SetImage(newimg,el,w,h)
	{
	if (el==null)
		{return true;}
	img=new Image();
	img.src=newimg;
	el.src='carrevide.gif'
//	while (el.complete==0)
//		{}
	if (w==0)
		{el.width=img.width;}		
	else
		{el.width=w;}
	if (h==0)
		{el.height=img.height;}
	else
		{el.height=h;}
	
	el.src=newimg;
	
//	while (el.complete==0)
//		{}
	}
function divlay()
{
	if (navigator.appName=="Netscape")
		return "layer";
	else
		return "div";
}
function divlaymod(name,texte)
{ 	
	if (navigator.appName=="Netscape")
	{
  		document.layers[name].document.write(texte);
  		document.layers[name].document.close();
 	}
 else
	document.all[name].innerHTML=texte;
}

derloc='';dertime=0;

function waitgo(doc,nbreimg,frme,loc,vgn)
//utilisee par les pages de droite de la section danse
{
//compte le nombre d'entree pour cette page
if (parent.frames['danseaff'].location!=='DanseLoading.htm')
	{parent.frames['danseaff'].location='DanseLoading.htm';}

//if (derloc!==doc.location)
//	{derloc=doc.location;
//	dertime=0;}
//else
//	{dertime=dertime+1}

cpt=0;
for (i=0;i<doc.images.length;i++)
	{if (doc.images[i].isloaded==1)
		cpt=cpt+1;
	 else
		{if (navigator.appName=="Netscape")
			if (doc.images[i].isloaded==undefined)
				{cpt=cpt+1;}
		}
	}

//si le nombre d'images du frame est charge ou si plus de 5s écoulees (10*500ms)
//on charge le frame
if (cpt==nbreimg) // || dertime>10)
	{
	if (frme.location!==loc)
		{w=parent.parent.frames['couverture'].window;
		w.change(vgn);
		frme.location=loc;}
	return true;
	}
else
	return false;

}
function getfilename(str)
{
	if (str==null)
		return 'a';
	lastsl=str.lastIndexOf('/');
	lastsl=lastsl+1;
	fich=str.substring(lastsl,str.length);
	return fich;
}
win2=window.opener;
function allera(pathsrc)
{
ns=0;ll=0;
if (navigator.appName=="Netscape")
	{ns=1}

if (screen.width>800)
	{ll=1}
if (ll==0)
{
	if (ns==1)
		{
		win2=window.open(pathsrc,"Peylan","toolbar=no, menubar=no, status=no, directories=no, resizable=yes, scrollbars=no, location=no");
		win2.window.outerWidth = 808;win2.window.outerHeight = 620;
		win2.window.moveTo (0,0)}
	else
		//ie fullscreen
		{win2=window.open(pathsrc,"Peylan","fullscreen,toolbar=no,scrollbars=no,location=0,menubar=0,resizable=no");}
}
else
	{
	ww=820
	lf=(screen.width-ww)/2
	win2=window.open(pathsrc,"Peylan","width=820, height=620, toolbar=no, menubar=no, status=no, directories=no, resizable=yes, scrollbars=no, location=no");
	win2.window.outerWidth = ww;win2.window.outerHeight = 620;
	win2.window.moveTo (lf, 0)}
}
function closeall()
{win2.close(); win2=null;}

// -->
