var myWin;
function showwindow(url, w, h) {
	if (w>0) l = (screen.width-w)/2;
	else {
		l=0;
		w = screen.width;
	}
	if (h>0) t = (screen.height-h)/2;
	else {
		t=0;
		h = screen.height;
	}

	if (!myWin || myWin.closed) { 
		myWin = window.open(url,
			"blank",
			"width="+w+",height="+h+","+
			"toolbar=0,location=0,"+
			"directories=0,status=0,"+
			"menubar=0,scrollbars=1,"+
			"resizable=0,"+
			"top="+t+","+
			"left="+l);
	} else {
		myWin.location = url;
		myWin.focus();
	} 
}
