	//SET DEFAULT VALUES
	var child = 0;
	var NS4 = 0;
	var IE4 = 0;
	var MacIE = 0;
	var Gen4 = 0;
	var WindowEnabled = 1;
	var IBS_Sitekey = 'ami';
	var IS_IA = true;


	//SET GLOBAL VARIABLES FOR BROWSER
	bName = navigator.appName;
	bVer = parseInt(navigator.appVersion);
	NS4 = (document.layers)? 1 : 0;
	MacIE = ( (navigator.userAgent.indexOf("IE 4")  > -1) && (navigator.userAgent.indexOf("Mac")  > -1) )? 1 : 0;
	IE4 = (document.all && !MacIE)? 1 : 0;
	Gen4 = (document.all || document.layers)? 1 : 0;
	//WindowEnabled = ((navigator.userAgent.indexOf("MSIE 4.0") >= 1))? 0 : 1;



	//OPEN WINDOW JS
	// takes all attributes in direct format
	function popUp(URL, ATTRIBUTES)  {
		DEF_ATTRIB = 'width=200,height=200,top=100,left=100,resizable=yes,scrollbars';
		if (ATTRIBUTES == null) {
			ATTRIBUTES = DEF_ATTRIB;
		}
		child = window.open(URL, "spawn", ATTRIBUTES);
		child.opener = self;
		if	(navigator.appName == 'Microsoft Internet Explorer' && parseInt(navigator.appVersion) == '2') {
			// Do Nothing
		} else {
			child.focus();
		}
	}


	function emailafriend(URL, ATTRIBUTES)
	//OPEN WINDOW JS
	// takes all attributes in direct format
{
	ATTRIBUTES = 'width=450,height=225,top=100,left=100,resizable=yes,scrollbars';
	MYURL = "http://cf.ibsys.com/ami/sh/toafriend/index.cfm?page=" + window.location;
	
	if (WindowEnabled){
		child = window.open(MYURL, "spawn", ATTRIBUTES);
		child.opener = self;
		if	(navigator.appName == 'Microsoft Internet Explorer' && parseInt(navigator.appVersion) == '2') {
			// Do Nothing
		} else {
			child.focus();
		}
	} else {
		document.location = MYURL;
	}
}

// Function to open videoblast windows //
function openVideo(sUrl, sName, sOptions) {
	window.open(sUrl,sName,sOptions+',scrollbars=no,resizable=1,top=50,left=50,width=780,height=504');
}


function imagePopup(img, sitekey, r) {
	if(img) window.open("http://wx.nbc6.net/services/640popup.cfm?img=" + img + ((sitekey)? "&sitekey=" + sitekey : "") + ((r)? "&r=" + r : ""), "Popup640", "width=680,height=665,scrollbars=0,toolbar=0,status=0,");
	else return false;
}
