
//++++++++++++++++++++++++++DEFAULT BROWSERCHECK+++++++++++++++++++++++++++++++++

function checkBrowser(){
	this.ver=navigator.appVersion	
	this.dom=document.getElementById?1:0
	this.ie5=(this.ver.indexOf("MSIE 5")>-1 && this.dom)?1:0;
	this.ie4=(document.all && !this.dom)?1:0;
	this.ns5=(this.dom && parseInt(this.ver) >= 5) ?1:0;
	this.ns4=(document.layers && !this.dom)?1:0;
	this.bw=(this.ie5 || this.ie4 || this.ns4 || this.ns5)
	return this
}

function openWin(strURL,strWinNM,strWinSize,bToolbar,bMenubar)
{	
	var iHeight = window.screen.availHeight;
	var iWidth = window.screen.availWidth;	

	var strFtrs = ""; //------ features------

	if(strWinSize) // ----- some other screen size --------
	{
		strFtrs = strWinSize
		if(iWidth > 800){strFtrs += ",top=" + (iHeight/20) + ",left=" + (iWidth /4)}
		else{strFtrs += ",top=" + (iHeight/30) + ",left=" + (iWidth /10)}
	}
	else // ----- go fullscreen --------
	{
		strFtrs = "height=" + iHeight + ",width=" + iWidth;
		strFtrs += ",top=0,left=0"
	}
	if(bToolbar){strFtrs += ",toolbar=1,location=0,status=0"} else {strFtrs += ",toolbar=0,status=0"};
	if(bMenubar) {strFtrs += ",menubar=1"} else {strFtrs += ",menubar=0"};
	strFtrs += ",scrollbars=1,resizable=1"
	//alert(strURL + strWinNM + "'" + strFtrs + "'")
	
	var win1 = window.open(strURL,strWinNM,strFtrs);
	if(win1 && win1.open && !win1.closed) win1.focus();
	
	return win1;
}