//window.name="HOMEPAGE";
var ua="UA";
ua=navigator.userAgent;
function whichBrowser() {
var br="BR";
if (ua.indexOf("MSIE") != -1) {br="IE";}
if ((ua.indexOf('Mozilla') != -1) && ((ua.indexOf('Spoofer') == -1) && (ua.indexOf('compatible') == -1))) {br="NS";}
return br;
}
function whichVersion(br) {
var bv=0;
bv=navigator.appVersion.substring(0,1);
if (br == "IE") {(parseInt(bv));}
if (br == "NS") {(parseInt(bv));}
return bv;
}
function whichPlatform() {
var os="OS";
if ((ua.indexOf("Win98")!=-1)||(ua.indexOf("Windows 98")!=-1)) { os='win32_98'; }
if ((ua.indexOf("Win95")!=-1)||(ua.indexOf("Windows 95")!=-1)) { os='win32_95'; }
else if ((ua.indexOf("WinNT")!=-1)||(ua.indexOf("Windows NT")!=-1)) {os='win32_NT'; }
else if ((ua.indexOf("Win16")!=-1)||(ua.indexOf("Windows 3.1")!=-1)) {os='win16'; }
else if ((ua.indexOf("Macintosh")!=-1)||(ua.indexOf("Mac")!=-1)) { os='Mac'; }
else if (ua.indexOf("SunOS")!=-1) { os='unix sun'; }
else if (ua.indexOf("IRIX")!=-1) { os='unix sgi'; }     
else if (ua.indexOf("HP-UX")!=-1) { os='unix hp'; }
else if (ua.indexOf("AIX")!=-1) { os='unix ibm'; }
else if (ua.indexOf("OS/2")!=-1) { os='os/2'; }
return os;
}

b=whichBrowser();
v=whichVersion(b);
o=whichPlatform();

function miniwinpopup(w, h, myurl, targetstring, l, t){
var popup=new Object();
popup.w=w;
popup.h=h;
popup.l=l;
popup.t=t;
popup.url=myurl;
popup.trgt=targetstring;

if (b=="IE") 
{
    if (v < 4)
    {
        // bug IE 3: top est pris pour left et rªciproquement
        window1=window.open(popup.url, popup.trgt, "width="+popup.w+",height="+popup.h+",resizable=0,status=0,left="+popup.t+",top="+popup.l+",menubar=0,scrollbars=0,toolbar=0,location=0,directories=0,");
        window2=window.open(popup.url, popup.trgt, "width="+popup.w+",height="+popup.h+",resizable=0,status=0,left="+popup.t+",top="+popup.l+",menubar=0,scrollbars=0,toolbar=0,location=0,directories=0,");
    }
    else
    {
        window1=window.open(popup.url, popup.trgt, "width="+popup.w+",height="+popup.h+",resizable=0,status=0,left="+popup.l+",top="+popup.t+",menubar=0,scrollbars=0,toolbar=0,location=0,directories=0,");
        window2=window.open(popup.url, popup.trgt, "width="+popup.w+",height="+popup.h+",resizable=0,status=0,left="+popup.l+",top="+popup.t+",menubar=0,scrollbars=0,toolbar=0,location=0,directories=0,");
    }       
}
else 
{
    if (v > 3) // Netscape 3 ne supporte pas left et top, la fen¹tre vient surcharger le site de fa°on disharmonieuse
    {
        window1=window.open(popup.url, popup.trgt, "width="+popup.w+",height="+popup.h+",resizable=0,status=0,left="+popup.l+",top="+popup.t+",menubar=0,scrollbars=0,toolbar=0,location=0,directories=0,");
        window1.focus();
        window2=window.open(popup.url, popup.trgt, "width="+popup.w+",height="+popup.h+",resizable=0,status=0,left="+popup.l+",top="+popup.t+",menubar=0,scrollbars=0,toolbar=0,location=0,directories=0,");
        window2.focus();
    }
}
}
//______________________________________________________________________________
function ouvreTout(page,nom,longueur,hauteur){
   if (nom=='' && whichBrowser()=='NS') nom='_blank';
      window.open(page,nom,"toolbar=no,width="+longueur+",height="+hauteur+",directories=no,location=no,status=no,scrollbars=yes,resizable=no,menubar=no");
}
//______________________________________________________________________________
var nava = (document.layers);
var dom = (document.getElementById);
var iex = (document.all);

function Loop(elem){
    elem1=elem.replace("tr_", "im_");
    obj=ToObj(elem);
    obj1=eval(elem1);
    if(obj.className=='sligne'){
        obj1.src=obj1.src.replace("+", "-");
        obj.className='bligne';
    }
    else{
        obj1.src=obj1.src.replace("-", "+");
        obj.className='sligne';
    }
}
//______________________________________________________________________________
function ToObj(elem){
    if (nava) obj = eval("document."+elem)
        else if (dom)  obj = eval("document.getElementById('"+elem+"')")
            else if (iex)  obj = eval(elem);
    return obj;
}
//______________________________________________________________________________
function band(){
    var type=document.frmband.btype.value;
    if(type==1){
        document.frmband.csport.value=0;
        document.frmband.csport.disabled=true;
        document.frmband.cpage.disabled=false;
    }
    else{
        document.frmband.cpage.value=0;
        document.frmband.cpage.disabled=true;
        document.frmband.csport.disabled=false;
    }
}

function MM_jumpMenu(targ,selObj,restore){
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}
function fullScreen(theURL) {
  window.open(theURL, '', 'fullscreen=yes, scrollbars=auto');
}
//---------------------------------------------------------------------------------
function get (cont,w,h) 
{
	var options = "height="+h+", width="+w+", toolbar=no, directories=no, status=no, scrollbars=auto, resizable=yes, menubar=no";
 	download = window.open(cont,"download", options);
 	download.focus();
 	return true;
}
//---------------------------------------------------------------------------------
function get2 (cont,w,h) 
{
	var options = "height="+h+", width="+w+", toolbar=no, directories=no, status=no, scrollbars=yes, resizable=yes, menubar=no";
 	download = window.open(cont,"download", options);
 	download.focus();
 	return true;
}