function popupWin(w,h,n,p){
	var winWide = Number(w);
	var winHeight = Number(h);
	var agent = navigator.userAgent;
	if (agent.indexOf('Windows') >= 0){
		winHeight += 60;
		winWide += 10;
	}
	if (agent.indexOf('MSIE 7.0') >= 0){ winHeight += 0; }
	if (agent.indexOf('MSIE 8') >= 0){
		winHeight += 56;
		winWide += 10;
	}
	if (agent.indexOf('Safari') >= 0){ winHeight += 24; }
	if (agent.indexOf('Opera') >= 0){ winHeight += 1; }
	if (agent.indexOf('Firefox') >= 0){ winHeight += 69; }
	//if (agent.indexOf('Windows') >= 0 && agent.indexOf('Firefox') >= 0){winHeight -= 10; }
	//alert(agent+"\n"+winWide+"x"+winHeight)
	//alert(agent+" // w="+winWide+", h="+winHeight+" // " + "w="+w+", h="+h+", n="+n+", p="+p);
	winOption = "width=" + winWide + ",height=" + winHeight + ",toolbar=no,directories=no,menubar=no,location=no,status=no,scrollbars=yes,resizable=yes";
	popupWindow = window.open(p,n,winOption);
	popupWindow.resizeTo(winWide,winHeight);
	popupWindow.focus();
}