//==========================================================================
// fnSpawnWindow(): Spawns a new window with no toolbars, and no menubars.  
//		The Url opened, whether or not there are scrollbars, the width and
//		height are defined by the parameters.
//
//		Input: string, integer (0 or 1), integer, integer
//		Output: window object
//==========================================================================
function spawnWindow(strUrl,intScroll,intWidth,intHeight) {
	var strWinFeatures = 'toolbars=0,menubar=0,scrollbars=' + intScroll + ',width=' + intWidth + ',height=' + intHeight;
	var objWindow	= window.open(strUrl, "subWindow", strWinFeatures);
}


var isNav = ((navigator.appName.indexOf("Netscape") != -1) && (navigator.appVersion.charAt(0) > 3));
var isIE  = (navigator.appName.indexOf("Microsoft") != -1);
var NotInChr13 = true;


function CheckForEnterKey(evtObj){
	if (isNav){
		var fldType = evtObj.target.type;
		var asciiVal  = evtObj.which;
	}
	if (isIE){
		var evtObj = window.event;
		var fldType = evtObj.srcElement.type;
		var asciiVal  = evtObj.keyCode;
	}
	if ((asciiVal == 13) || (asciiVal == 3)){
		NotInChr13 = false;
		if (isIE){
			if ('undefined' != '' + fldType){
				fnSubmitForm(document.forms[0],'name');
			}
  		}else{
			if (fnValidateTxtFld(document.forms[0])){
				document.forms[0].submit();
			}
		}
		NotInChr13 = true;
	}
}

if (isNav) document.captureEvents(Event.KEYPRESS);
document.onkeypress=CheckForEnterKey;