function ZoomIt( sImgFileName, nBorderInPixel, bOtherZoomWin ) {
	var d = new Date();
	var sPageName = 'ZoomPage';
	if (bOtherZoomWin) sPageName='Zoom'+d.getHours()+d.getMinutes()+d.getSeconds();

	wWin=window.open('',sPageName,'width=200, height=200, resizable, scrollbars=1');

	wWin.document.write('<html><head><title>Gallery</title>\n');

	wWin.document.write('<scri'+'pt language="javascript">\n');	//script = scri+pt per non avere problemi di visualizzazione codice in DW
	wWin.document.write('\n');

	wWin.document.write('var isNS4 = (navigator.appName.indexOf("Netscape") >= 0 && \n');
	wWin.document.write('                parseFloat(navigator.appVersion) >= 4) ? 1 : 0; \n');
	wWin.document.write('var isIE4 = (document.all) ? 1 : 0; \n');
	wWin.document.write('\n');
	wWin.document.write('\n');

	wWin.document.write('function ResizeMe() { \n');
	wWin.document.write('if (isNS4) { \n');
	wWin.document.write('window.innerWidth = document.layers[0].document.images[0].width+'+2*nBorderInPixel+'; \n');
	wWin.document.write('window.innerHeight = document.layers[0].document.images[0].height+'+2*nBorderInPixel+'; \n');
	wWin.document.write('} \n');
	wWin.document.write('if (isIE4) { \n');
	wWin.document.write('window.resizeTo(500, 500); \n');
	wWin.document.write('width = 500 - (document.body.clientWidth -  document.images[0].width) + '+2*nBorderInPixel+'; \n');
	wWin.document.write('height = 500 - (document.body.clientHeight -  document.images[0].height) + '+2*nBorderInPixel+'; \n');
	wWin.document.write('window.resizeTo(width, height); \n');
	wWin.document.write('   } \n');
	wWin.document.write('} \n');
	wWin.document.write('\n');
	wWin.document.write('\n');

	wWin.document.write('</scri'+'pt>\n');	//script = scri+pt per non avere problemi di visualizzazione codice in DW
	wWin.document.write('\n');
	wWin.document.write('\n');

	wWin.document.write('</head><body onLoad="ResizeMe();" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">\n');
	wWin.document.write('\n');
	wWin.document.write('<img id="immagine" src="'+ sImgFileName+ '" border="1" style="1px, solid, #000000" />\n');
	wWin.document.write('\n');
	wWin.document.write('</body></html>\n');


	wWin.document.close();

}

//--Funzione per gestire le POPUP      
function DoPopUp(URL,Name,X,Y,Center,Resizable,ScrollBars){

  //Center = yes or no
  //Resizable = yes or no
  //ScrollBars = yes or no

  if (Center == 'yes'){
    var PopUpX = (screen.width/2)-(parseInt(X)/2);
    var PopUpY = (screen.height/2)-(parseInt(Y)/2);
    var pos = ",left="+PopUpX+",top="+PopUpY;
  }else{
    var pos = "";
  }
  PopUpWindow = window.open(URL,Name,'scrollbars='+ScrollBars+',resizable='+Resizable+',width='+X+',height='+Y+pos);
}
//--------------------------------------------------------------------