// JavaScript Document	
function openWindow(mypage,myname,w,h,mode){

var win= null;
var winl = (screen.width-w)/2;
var wint = (screen.height-h)/2;

switch(mode){
	case 'tr':
	winl = (screen.width-w);
	wint = 0;
	break;	
	
	case 'tl':
	winl = 0;
	wint = 0;
	break;	
	
	case 'bl':
	winl = 0;
	wint = (screen.height-h);
	break;
	
	case 'br':
	winl = (screen.width-w);
	wint = (screen.height-h);
	break;
}

settings='height=' +h+ ',width=' +w+ ',top=' +wint+ ',left=' +winl+ ',scrollbars=no,toolbar=no';
win=window.open(mypage,myname,settings)
if(parseInt(navigator.appVersion) >= 4){win.window.focus();}
}
