var isNav4, isIE4, isMac, isNav6;

if( parseInt( navigator.appVersion.charAt( 0 )) >= 4) {
	isNav4 = ( navigator.appName == "Netscape" && parseInt( navigator.appVersion ) != 5 ) ? true : false
	isNav6 = ( navigator.appName == "Netscape" && parseInt( navigator.appVersion ) == 5 ) ? true : false
	isIE4 = ( navigator.appName.indexOf( "Microsoft" ) != -1 ) ? true : false
	isMac = ( navigator.platform.indexOf( "Mac" ) != -1 ) ? true : false
}
		
function doSubWin( url, winWidth, winHeight ) {
	if( isNav4 || isIE4 ) {
		var screenPosX,screenPosY;
		screenPosX = ( screen.availWidth - winWidth ) / 2;
		screenPosY = ( screen.availHeight - winHeight ) / 2;
				
		if( isNav4 ) {
			window.open( url, 'subwin','toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0, copyhistory=0,width=' + winWidth + ',height=' + winHeight + ',screenX=' + screenPosX + ',screenY=' + screenPosY );
		}
			
		if( isIE4 ) {
			newwin = window.open( url, 'subwin','toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0, copyhistory=0,width=' + winWidth + ',height=' + winHeight + ',left=' +screenPosX+ ',top=' + screenPosY );
		}
	} else {
		window.open( url, 'subwin','toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=1,resizable=1, copyhistory=0,width=' + winWidth + ',height=' + winHeight );
	}
}
