function chromeless(u,n,W,H,X,Y,tW,wNS,fSO,brd,max,min,res,tsz,totfoto,scrollbars){
	var c=(document.all&&navigator.userAgent.indexOf("Win")!=-1)?1:0
	var v=navigator.appVersion.substring(navigator.appVersion.indexOf("MSIE ")+5,navigator.appVersion.indexOf("MSIE ")+8)
	min=(v>=5.5?min:false);
	var w=window.screen.width; var h=window.screen.height
	var W=W||w; W=(typeof(W)=='string'?Math.ceil(parseInt(W)*w/100):W); W+=(brd*2+2)*c
	var H=H||h; H=(typeof(H)=='string'?Math.ceil(parseInt(H)*h/100):H); H+=(tsz+brd+2)*c

	var X=X||Math.ceil((w-W)/2)
	var Y=Y||Math.ceil((h-H)/2)
	
	var s1=",width="+W+",height="+H+",innerWidth="+W+",innerHeight="+H
    var s2=s1+",left="+X+",top="+Y+",screenX="+X+",screenY="+Y
	
	var CWIN=window.open(u,n,wNS+s2,true)
	//CWIN.moveTo(X,Y)
	
	CWIN.focus()
	CWIN.setURL=function(u) { if (this && !this.closed) { if (this.frames.main) this.frames.main.location.href=u; else this.location.href=u } }
	CWIN.closeIT=function() { if (this && !this.closed) this.close() }
	return CWIN
}                                                                               
                                                                               

function openIT(nomefin,u,W,H,X,Y,n,b,x,m,r,totfoto,scrb) {

	var tW  = nomefin
	var wNS ='toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars='+scrb+',resizable=yes'
	var fSO ='scrolling=auto'
	var brd =b||0;
	var max =x||false;
	var min =m||false;
	var res =r||false;
	var tsz =20;
	return chromeless(u,n,W,H,X,Y,tW,wNS,fSO,brd,max,min,res,tsz,totfoto,scrb)
}