//*********** partie scroll  *********
var speed=50

var loop, timer
function checkBrowser(){
this.ver=navigator.appVersion
this.dom=document.getElementById?1:0
this.ie5=(this.ver.indexOf("MSIE 5")>-1 && this.dom)?1:0;
this.ie4=(document.all && !this.dom)?1:0;
this.ns5=(this.dom && parseInt(this.ver) >= 5) ?1:0;
this.ns4=(document.layers && !this.dom)?1:0;
this.bw=(this.ie5 || this.ie4 || this.ns4 || this.ns5)
return this
}
bw=new checkBrowser()


function makeObj(obj,nest,nest2){
nest=(!nest) ? '':'document.layers.'+nest+'.'
nest=(!nest2)?nest:nest='document.layers.'+nest2+'.'+nest
this.el=bw.dom?document.getElementById(obj):bw.ie4?document.all[obj]:bw.ns4?eval(nest+'document.layers.'+obj):0;
this.css=bw.dom?document.getElementById(obj).style:bw.ie4?document.all[obj].style:bw.ns4?eval(nest+'document.layers.'+obj):0;
this.scrollHeight=bw.ns4?this.css.document.height:this.el.offsetHeight
this.clipHeight=bw.ns4?this.css.clip.height:this.el.offsetHeight
this.up=goUp;this.down=goDown;
this.moveIt=moveIt; this.x; this.y;
this.obj = obj + "Object"
eval(this.obj + "=this")
return this
}

function moveIt(x,y){
	this.x=x;this.y=y
	this.css.left=this.x
	this.css.top= (!document.getElementById && !document.all) ? this.y : this.y+"px"
}


function goDown(move){
if(this.y>-this.scrollHeight+oCont.clipHeight){
this.moveIt(0,this.y-move)
if(loop) setTimeout(this.obj+".down("+move+")",speed)
}
}

function goUp(move){
	if(this.y<0){
		this.moveIt(0,this.y-move)
		if(loop) setTimeout(this.obj+".up("+move+")",speed)
	}
}

function scroll(speed,val){
	if(loaded){
		loop=true;
		switch(val)
		{
			case 1 :
				oCont=oCont1;
				if(speed>0) oScroll1.down(speed);
				else oScroll1.up(speed);
				break;
			case 2 :
				oCont=oCont2;
				if(speed>0) oScroll2.down(speed);
				else oScroll2.up(speed);
				break;
			case 3 :	
				oCont=oCont3;
				if(speed>0) oScroll3.down(speed);
				else oScroll3.up(speed);
				break;
			case 4 :	
				oCont=oCont4;
				if(speed>0) oScroll4.down(speed);
				else oScroll4.up(speed);
				break;
			case 5 :
				oCont=oCont5;
				if(speed>0) oScroll5.down(speed);
				else oScroll5.up(speed);
				break;
		}
	}
}


function noScroll(){
	loop=false
	if(timer) clearTimeout(timer)
}

var oCont;
var loaded;
function scrollInit(){
/*	oCont1=new makeObj('divCont1')
	oScroll1=new makeObj('texte1','divCont1')
	oScroll1.moveIt(0,0);
	
	oCont2=new makeObj('divCont2')
	oScroll2=new makeObj('texte2','divCont2')
	oScroll2.moveIt(0,0);
	
	oCont3=new makeObj('divCont3')
	oScroll3=new makeObj('texte3','divCont3')
	oScroll3.moveIt(0,0);
*/
if(scroll4)
{	
	oCont4=new makeObj('divCont4','corpsdroite')
	oScroll4=new makeObj('texte4','divCont4','corpsdroite')
	oScroll4.moveIt(0,0);
}
if(scroll5)
{	
	oCont5=new makeObj('divCont5','corpsdroite')
	oScroll5=new makeObj('texte5','divCont5','corpsdroite')
	oScroll5.moveIt(0,0);
}		
	loaded=true;
}

//onload = scrollInit




/* partie affiche les divs */

function mybrowser2(nomdiv){
if (document.getElementById) {
        // NS6
		namediv = "document.getElementById(\""+ nomdiv + "\").style";
		}
else if (document.layers) {
		// NS4
		namediv = "document.divCont.document."+ nomdiv
		}
else if (document.all) {
        // IE4
        namediv = "document.all[\""+ nomdiv + "\"].style";
		}
}
 
 /* open win */

function openWin(url, nom, winOpts)
{
	var MinWin;
	MinWin = window.open(url, nom, winOpts);
	if (navigator.appVersion.indexOf("(X11") != -1 ||
		navigator.appVersion.indexOf("(Mac") != -1)
	 MinWin = window.open(url, nom, winOpts);
	if (navigator.appName == "Netscape" && (parseInt(navigator.appVersion) >=3 )) {
		MinWin.focus()
	}
}
window.name='cliclait'
tmpimg=new Image();