function credit(){
	window.open('jsp/front/credit_sqli.jsp','credit','width=300,height=120');
}

 function BrowserCheck(){ 
  var b = navigator.appName 
  if (b=="Netscape") this.b = "ns" 
  else if (b=="Microsoft Internet Explorer") this.b = "ie" 
  else this.b = b 
  this.v = parseInt(navigator.appVersion) 
  this.ns = (this.b=="ns" && this.v>=4) 
  this.ns4 = (this.b=="ns" && this.v==4) 
  this.ns5 = (this.b=="ns" && this.v==5) 
  this.ie = (this.b=="ie" && this.v>=4) 
  this.ie4 = (navigator.userAgent.indexOf('MSIE 4')>0) 
  this.ie5 = (navigator.userAgent.indexOf('MSIE 5')>0) 
  if (this.ie5) this.v = 5 
  this.min = (this.ns||this.ie) 
 } 

 function swap_img(imgname,imgpic){
  document.images[imgname].src='images/'+imgpic;
 }

 var is = new BrowserCheck();
 var agt=navigator.userAgent.toLowerCase();
 var mac = (agt.indexOf("mac")!=-1);

 if(is.ie || is.ns5)
  document.write("<link rel='stylesheet' type='text/css' href='styles/iestyle.css'>");
 else if(is.ns)
  if (mac)
  document.write("<link rel='stylesheet' type='text/css' href='styles/iestyle.css'>");
  else
  document.write("<link rel='stylesheet' type='text/css' href='styles/nnstyle.css'>");

 function acces_client(){
 if(is.ie)
  if(document.all['acces'].style.visibility=="visible")
   document.all['acces'].style.visibility="hidden";
  else{
   document.all['acces'].style.visibility="visible";
   document.all.login.focus();
   }
 else if(is.ns5)
  if(document.getElementById('acces').style.visibility=="visible")
   document.getElementById('acces').style.visibility="hidden";
  else{
   document.getElementById('acces').style.visibility="visible";
   document.all.login.focus();
   }
 else if(is.ns)
  if(document.acces.visibility == 'show')
   document.acces.visibility = 'hide';
  else{
   document.acces.visibility = 'show';
   document.all.login.focus();
   }
   
 }

function open_popup(){
  var link =location.href+"&print=true";
  mainWin = window.open(link,"popup","menubar=1,statusbar=1,scrollbars=1,width=610,height=450");
}

function popup_home(link){
  //mainWin = window.open(link,"popup","menubar=0,status=1,scrollbars=0,width=645,height=470,left=0,top=0");
  displayPopup(link,"popup") ; 
}

function popup_lieux(link){
  displayPopupLieuxEcoute(link,"popup") ;
  
}

function imprimer(){
   window.print();
}
  




function displayPopup(url,name) {

	var properties = "menubar=0,status=1,scrollbars=0,width=645,height=470";
	var leftprop, topprop, screenX, screenY, cursorX, cursorY, padAmt;
	
	if(navigator.appName == "Microsoft Internet Explorer") {
		screenY = document.body.offsetHeight;
		screenX = window.screen.availWidth;
	}
	else {
		screenY = window.outerHeight
		screenX = window.outerWidth
	}
	
	
	leftvar = (screenX - 645) / 2;
	rightvar = (screenY - 470) / 2;
	
	if(navigator.appName == "Microsoft Internet Explorer") {
		leftprop = leftvar;
		topprop = rightvar;
	}else {
		leftprop = (leftvar - pageXOffset);
		topprop = (rightvar - pageYOffset);
	}
	
	properties = properties + ", left = " + leftprop;
	properties = properties + ", top = " + topprop;
	

 	window.open(url,name,properties);
}



function displayPopupLieuxEcoute(url,name) {

	var properties = "menubar=0,status=1,scrollbars=1,width=645,height=500";
	var leftprop, topprop, screenX, screenY, cursorX, cursorY, padAmt;
	
	if(navigator.appName == "Microsoft Internet Explorer") {
		screenY = document.body.offsetHeight;
		screenX = window.screen.availWidth;
	}
	else {
		screenY = window.outerHeight
		screenX = window.outerWidth
	}
	
	
	leftvar = (screenX - 645) / 2;
	rightvar = (screenY - 470) / 2;
	
	if(navigator.appName == "Microsoft Internet Explorer") {
		leftprop = leftvar;
		topprop = rightvar;
	}else {
		leftprop = (leftvar - pageXOffset);
		topprop = (rightvar - pageYOffset);
	}
	
	properties = properties + ", left = " + leftprop;
	properties = properties + ", top = " + topprop;
	

 	window.open(url,name,properties);
}




function OpenPopUp(strURL) {

window.open(strURL,"popup","");

}

function OuvrePopUp(Url,Title,Param,Width,Heigth)
{
	if ((Param == "") && (Width == "") && (Heigth == "")) {
        	window.open(Url,Title);
        	}
	else if (Param == "") {
        	Param = "width=" + Width + ",height=" + Heigth;
        	window.open(Url,Title,Param);
        	}
        else {
                Param += ",width=" + Width + ",height=" + Heigth;
                window.open(Url,Title,Param);
                }
}
  