function popup(url, width, height, scrollbar) {
	
	if (typeof width == "undefined" || width == null)
		width = 700;
	if (typeof height == "undefined" || height == null)
		height = 400;
	if (typeof scrollbar == "undefined" || scrollbar == null)
		scrollbar = 'no';
	var left = (screen.width - width) / 2;
	var top  = (screen.height - height) / 2;

	winprops = 'height='+height+',width='+width+',top='+top+',left='+left+',scrollbars='+scrollbar+',resizable'
	win = window.open(url, 'popuppage', winprops)
	if (parseInt(navigator.appVersion) >= 4) {
		win.window.focus();
	}

}
