<!--
var tempRGB = new Array(3);
var RGB = new Array(256);
var HSL = new Array(3);
var red=0,blue=0,green=0,compRed=0,compGreen=0,compBlue=0;
var increment=0;
var k = 0;
var hex = new Array("0", "1", "2", "3", "4", "5", "6", "7", "8", "9", "A", "B", "C", "D", "E", "F");
var loaded = (!(navigator.userAgent.indexOf("Gecko")+1));
var Etat = 0

browserName = navigator.appName;
browserVer = parseInt(navigator.appVersion);

visible = "visible";

if (browserName == "Netscape" && browserVer >= 4  && browserVer <5) {
	layerRef = "document.layers";
	stylepro="";
	Brws = "NN4";
	T = 1;
	}


if (document.all&&!window.print) {
	layerRef = "document.all";
	stylepro =".style";
	Brws = "IE4";
	T = 0;
	}


if (document.getElementById&&document.all) {
	layerRef = "document.getElementById";
	stylepro =".style";
	Brws = "IE5+";
	T = 0;
	}

if (document.getElementById&&!document.all)
	{
	layerRef = "document.getElementById";
	stylepro = ".style";
	Brws = "NN5"
	T = 2;
	}



function openimage(file)
{
coolwin = window.open("","ImageIn","width=400,height=300,scrollbars=No");
with (coolwin)
	{
	document.open ('text/html');
	document.writeln ('<HTML><HEAD><Title>SDI-PHOTO</title><META HTTP-EQUIV="imagetoolbar" CONTENT="no">');
	document.writeln ('<link rel="stylesheet" href="cool.css"></HEAD><BODY BGCOLOR=white leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">');
	document.writeln ('<center><Img Src="'+file+'"></center>');
	document.writeln ('<script language=JavaScript>');
	document.writeln ('<!--');
	document.writeln ('var msge="Impossible";');
	document.writeln ('function clickIE() {if (document.all) {(msge);return false;}}');
	document.writeln ('function clickNS(e) {if ');
	document.writeln ('(document.layers||(document.getElementById&&!document.all)) {');
	document.writeln ('if (e.which==2||e.which==3) {(message);return false;}}}');
	document.writeln ('if (document.layers) ');
	document.writeln ('{document.captureEvents(Event.MOUSEDOWN);document.onmousedown=clickNS;}');
	document.writeln ('else{document.onmouseup=clickNS;document.oncontextmenu=clickIE;}');
	document.writeln ('document.oncontextmenu=new Function("return false")');
	document.writeln ('// --> ');
	document.writeln ('</script>');
	document.writeln ('</BODY></HTML>');
	document.close();
	}
}

function hidelayer(layer)
{
if (Brws == "NN4" || Brws == "IE4" )
{
eval(layerRef+'.'+layer+stylepro+'.visibility= "visible"');
}
else
{
eval(layerRef+'("'+layer+'")'+stylepro+'.visibility= "visible"');
}
}

function hidelayer2(layer)
{
if (Brws == "NN4" || Brws == "IE4" )
{
eval(layerRef+'.'+layer+stylepro+'.visibility= "hidden"');
}
else
{
eval(layerRef+'("'+layer+'")'+stylepro+'.visibility= "hidden"');
}
}

function showlayer(layer)
{
if (Brws == "NN4" || Brws == "IE4" )
{
eval(layerRef+'.'+layer+stylepro+'.visibility= "visible"');
}
else
{
eval(layerRef+'("'+layer+'")'+stylepro+'.visibility= "visible"');
}
}


function mywindow(lien,nomfen,taillex,tailley,scrolls)
{
mywin2 = eval("window.open('" + lien + "','" + nomfen + "','width=" + taillex + ",height=" + tailley + ",scrollbars=" + scrolls + "');");
mywin2.focus();
//return false;
}


liens = new Array();
Banurls = new Array();
Descr = new Array();
Size = new Array();

liens[-1]= "#"
Banurls[-1] = "images/blank.gif";
Descr[-1] = "#"
liens[0]= "roquefeuil.html"
Banurls[0] = "Pubs/roquefeuille.gif";
Descr[0] = "#"
Size[0] = new Array(274,600,"no"); // défini la taille de la fenêtre à ouvrir et si elle possede ou non un scrollbars

liens[1]= "roquefeuil.html"
Banurls[1] = "Pubs/roquefeuille.gif";
Descr[1] = "Le Mont Roquefeuil"
Size[1] = new Array(274,600,"no");

liens[2]= "soit.html"
Banurls[2] = "Pubs/soit.gif";
Descr[2] = "S.A.R.L Océan Indien Topographie"
Size[2] = new Array(290,550,"yes");

liens[3]= "http://www.immopays.com"
Banurls[3] = "Pubs/ca.gif";
Descr[3] = "Le Portail Immobilier du Crédit Agricole de la Réunion"
Size[3] = new Array(800,600,"yes");

function cyclepub()
{
m = Math.random()*(Banurls.length-2)+1;
t = Math.round(m);
//if (m==0) m = 1
if (T==0)
{
BanPub.innerHTML = '<table width="510" height="52" border="0" cellspacing="0" cellpadding="0">  <tr>      <td><A href="#" onClick="mywindow(\''+liens[t]+'\',\'supa\','+Size[t][0]+','+Size[t][1]+',\''+Size[t][2]+'\');"><Img src="'+ Banurls[t] +'" name="image2" width="510" height="52" border="0" Alt="' + Descr[t] + '"></a></td>    </tr> </table>';
//eval(layerRef + '.id1.document.image2.src ="' + Banurls[t]+'";');
}

if (T==1) 
	{
	with (document.layers.BanPub.document)
		{
	open ('text/html');
	writeln('<table width="510" height="52" border="0" cellspacing="0" cellpadding="0">  <tr>      <td><A href="#" onClick="mywindow(\''+liens[t]+'\',\'supa\','+Size[t][0]+','+Size[t][1]+',\''+Size[t][2]+'\');"><Img src="'+ Banurls[t] +'" name="image2" width="510" height="52" border="0" Alt="' + Descr[t] + '"></a></td>    </tr> </table>');
//	eval(layerRef + '.id1.document.image2.src ="' + Banurls[t]+'";');
	close();
		}
	}
	
if (T==2)
{
document.getElementById("BanPub").innerHTML = '<table width="510" height="52" border="0" cellspacing="0" cellpadding="0">  <tr>      <td><A href="#" onClick="mywindow(\''+liens[t]+'\',\'supa\',\''+Size[t][0]+','+Size[t][1]+','+Size[t][2]+'\');"><Img src="'+ Banurls[t] +'" name="image2" width="510" height="52" border="0" border="0" Alt="' + Descr[t] + '"></a></td>    </tr> </table>';
//eval(layerRef + '.id1.document.image2.src ="' + Banurls[t]+'";');
}	

setTimeout("cyclepub()",6000);
return false;
}
// -->