  // Copyrigth 2002 Peopleware (www.peopleware.lu)
  // All right reserved. Could not be used without a writted authorisation
  //
  // Author: nr@peopleware.lu && gs@audaxis.com
  //
  
  function displayCenterPopUp(baseurl, popUpName, popUpWidth, popUpHeight) {
  	screenXWindow 	= (screen.width - popUpWidth) / 2;
  	screenYWindow 	= (screen.height - popUpHeight) /2;
  	
	netFiche = window.open (baseurl, "", 'top='+screenYWindow+',left='+screenXWindow+',resizable=yes,scrollbars=yes,status=yes,width='+popUpWidth+',height='+popUpHeight);
	netFiche.focus();  
  }

  function displayCenterFixPopUp(baseurl, popUpName, popUpWidth, popUpHeight) {
  	screenXWindow 	= (screen.width - popUpWidth) / 2;
  	screenYWindow 	= (screen.height - popUpHeight) /2;
  	
	netFiche = window.open (baseurl, popUpName, 'toolbar=no, directories=no, location=no,status=no, menubar=no, resizable=no,scrollbars=no, top='+screenYWindow+',left='+screenXWindow+',width='+popUpWidth+',height='+popUpHeight);
	netFiche.focus();  
  }

  function openPopupNetFicheVlanId(baseurl,id) {
  	displayCenterPopUp(baseurl+'?adID='+id, 'NetFiche'+id, 600, 400);
  }  
  
  function openPopupNetFiche(baseurl,id) {
  	displayCenterPopUp(baseurl+'?ID='+id, 'NetFiche'+id, 600, 400);
  } 
  
  function openPopupAlbum (photo1, photo2, photo3, photo4, photo5) {
  	 	var url = '/vlan-immo/album_photo.jsp?'
  	 	var existPhoto = false;
  	 	if (photo1!='nopicture' && photo1 !='') {
	  	 	if (existPhoto==true) { url+='&';}
  	 		url+='picture1='+photo1+'_n_new.JPG';
  	 		existPhoto = true;
  	 	}
  	 	if (photo2!='nopicture' && photo2 !='') {
	  	 	if (existPhoto==true) { url+='&';}
  	 		url+='picture2='+photo2+'_n_new.JPG';
  	 		existPhoto = true;
  	 	}
  	 	if (photo3!='nopicture' && photo3 !='') {
	  	 	if (existPhoto==true) { url+='&';}
  	 		url+='picture3='+photo3+'_n_new.JPG';
  	 		existPhoto = true;
  	 	}
 	 	if (photo4!='nopicture'  && photo4 !='') {
	  	 	if (existPhoto==true) { url+='&';}
  	 		url+='picture4='+photo4+'_n_new.JPG';
  	 		existPhoto = true;
  	 	}
  	 	if (photo5!='nopicture'  && photo5 !='') {
	  	 	if (existPhoto==true) { url+='&';}
  	 		url+='picture5='+photo5+'_n_new.JPG';
  	 		existPhoto = true;
  	 	}
  	 	if (existPhoto==true) {
  	 		url+='&imagePath=./image/users/';
  	 		displayCenterPopUp(url,'Album Photo',680,580);
  	 	}
  }
