

function readCookie(cookiename)
	{	if(document.cookie == '') 
			{	// there's no cookie, so go no further
				return false;
			}
		else
			{	var firstChar, lastChar;
				var theWholeCookie = document.cookie;
				firstChar = theWholeCookie.indexOf(cookiename);		// find the start of 'cookiename'
				firstChar += cookiename.length + 1;					// skip 'name' and '='
				lastChar = theWholeCookie.indexOf(";",firstChar);			// Find the end of the value string (i.e. the next ';')
				if(lastChar == -1)
					{	lastChar = theWholeCookie.length;
					}
				return unescape(theWholeCookie.substring(firstChar, lastChar));
			}
	}


// function to split a whole info cookie (using "|" as the delimeter
var wholeinfos = new Array;
function splitWholePdfCookie(cookieName)
	{	
		// load the cookie into a variable
		var the_info_cookie = readCookie(cookieName);
		if (the_info_cookie.indexOf("=") == -1)
			{	wholeinfos[0] = the_info_cookie;
			}
		else 
			{	
				wholeinfos = the_info_cookie.split("=");
			}
	}


//document object model - The code senses which DOM thr browser uses and assigns the appropriate variable to have a value of 1 (true). 
//if any DOM is detected, the isDHTML variable is set to true

var isDHTML = 0; //initialising to false
var isLayers = 0;//initialising to false
var isAll = 0;//initialising to false
var isID = 0;//whether any DOM is present - whether the browser is DHTML capable

if (document.getElementById) {//detect for each dom
	isID = 1; //if that DOM works in that browser, assign the corresponding variable to 1 (true) 
	isDHTML = 1;
}
else {
	browserVersion = parseInt(navigator.appVersion);
	if ((navigator.appName.indexOf('Netscape') != -1) && (browserVersion == 4))
	{
		isLayers = 1; isDHTML = 1;
	}
	else
	{
		if (document.all) 
		{
			isAll = 1; isDHTML = 1;
		}
	}
}

function findDOM(objectID,withStyle) {
var menuArea = "menuArea";
	if (withStyle == 1) {
		if (isID) { return (document.getElementById(objectID).style) ; }
		else { 
			if (isAll) { return (document.all[objectID].style); }
		else {
			if (isLayers) { return (document.layers[menuArea].layers[objectID]); }
		};}
	}
	else {
		if (isID) { return (document.getElementById(objectID)) ; }
		else { 
			if (isAll) { return (document.all[objectID]); }
		else {
			if (isLayers) { return (document.layers[menuArea].layers[objectID]); }
		};}
	}
}
<!--
function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);
//-->