var dom = (document.getElementById) ? true : false;var ns5 = ((navigator.userAgent.indexOf("Gecko")>-1) && dom) ? true: false;var ie5 = ((navigator.userAgent.indexOf("MSIE")>-1) && dom) ? true : false;var ns4 = (document.layers && !dom) ? true : false;var ie4 = (document.all && !dom) ? true : false;var nodyn = (!ns5 && !ns4 && !ie4 && !ie5) ? true : false;function strLeft(sourceStr, keyStr){	return (sourceStr.indexOf(keyStr) == -1 | keyStr=='') ? '' : sourceStr.split(keyStr)[0];}function strRight(sourceStr, keyStr){	idx = sourceStr.indexOf(keyStr);	return (idx == -1 | keyStr=='') ? '' : sourceStr.substr(idx+ keyStr.length);}//@RightBack equivalentfunction rightBack(sourceStr, keyStr){	arr = sourceStr.split(keyStr);	return (sourceStr.indexOf(keyStr) == -1 | keyStr=='') ? '' : arr.pop()}//@LeftBack equivalentfunction leftBack(sourceStr, keyStr){	arr = sourceStr.split(keyStr)	arr.pop();	return (keyStr==null | keyStr=='') ? '' : arr.join(keyStr)}function readCookie(name) {	var nameEQ = name + "=";	var ca = document.cookie.split(';');	for(var i=0;i < ca.length;i++) {		var c = ca[i];		while (c.charAt(0)==' ') c = c.substring(1,c.length);		if (c.indexOf(nameEQ) == 0) return c.substring(nameEQ.length,c.length);	}	return null;}function groupClick( curGroup, curID, groupSize, baseStyle ){	for (i=1; i<=groupSize;i++) {		itemName = curGroup + i;		elem = (ie4)? document.all[itemName]: (ie5||ns5)? document.getElementById(itemName): null;		try {			elem.className = baseStyle + ((i == curID)? "Clicked": "");		}		catch (e) {}	}} var doc = window.document;function notYou() {	document.cookie = "disSubscriber=; expires=; path=/";	document.cookie = "disID=; expires=; path=/";		var userItem = document.getElementById("thisUser");	var logiItem = document.getElementById("login");		userItem.style.display = "none";	logiItem.innerHTML = "Login";	window.location = "/?????????/dscli.nsf?Logout&Redirectto=/";}function procUser() {//alert("procUser");	oPage =  location.search.substring(1,  location.search.length);	if( oPage != "") {		if ( oPage.indexOf( "lic=" ) == 0){//alert("Got lic");					window.location = "/??????/licdata?openagent&lic="  + oPage.substring(4);		}	}	var userItem = document.getElementById("thisUser");	var logiItem = document.getElementById("login");	var subsItem = document.getElementById("subs");	var uname = "";		licCode = readCookie( "dislicCode" );	if (licCode != null && licCode != "") {		var recentIssue = document.getElementById("MM2");		recentIssue.href = "/?????????/dssetup.nsf/ra?openagent"  + "&lic=" + licCode;		logiItem.style.display="none";		subsItem.style.display="none";	} else {		try {			IPname = readCookie( "IPname" );			uname = readCookie( "disSubscriber");		}		catch (e) {}//alert("in else 11");				if (IPname != null && IPname != "") {			logiItem.style.display="none";			subsItem.style.display="none";			userItem.innerHTML = uname;		} else {			if (uname != null && uname != "" ) {				userItem.style.display="";				subsItem.style.display ="none";				userItem.innerHTML = uname + ' <a href="#" onClick="notYou();">&nbsp;&nbsp;Not you?</a>';				logiItem.innerHTML = "My profile";						} else {				logiItem.style.display="";				subsItem.style.display="";								logiItem.innerHTML = "Login";				subsItem.innerHTML = "Subscribe";			}		}	}}function showRegLinks(optURL){//Note: for these functions to work the site definition in the dom directory must not start with a "/"	domid = readCookie( "DomAuthSessId" );	basePath = location.pathname;	basePath = leftBack( strLeft( basePath.toLowerCase(),".nsf"),"/")+ "/";		if (domid == null || domid == "") {		URL = (optURL!="")? optURL : basePath + "wappuib.nsf/newacc!openform";		document.write("<a href='" + URL + "'>Register</a>");	} else {		//logoutURL = "/&logout";		//var uname = document.getElementById("uname");		dashURL = basePath + "wappuib.nsf/pl!openform"		document.write("<a href='" + dashURL + "'>Dashboard</a>");	}}function showLoginLinks(){//Note: for these functions to work the site definition in the dom directory must not start with a "/"	domid = readCookie( "DomAuthSessId" );	basePath = location.pathname;	basePath = leftBack( strLeft( basePath.toLowerCase(),".nsf"),"/")+ "/";				if (domid == null || domid == "") {		loginURL = basePath + "wappuib.nsf/pl!openform&login";		document.write("<a href='" + loginURL + "'>Login</a>");	} else {		logoutURL = basePath + "wappUIB.nsf!Logout&Redirectto=/";		var uname = document.getElementById("uname");		document.write("<a href='" + logoutURL + "'>Logout</a>");	}}//window.onload = procUser;