// Script Library for www.ambia-inc.comfunction MM_findObj(n, d) { //v4.01  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);  if(!x && d.getElementById) x=d.getElementById(n); return x;}/*function showHide() { //v6.0  var i,p,v,obj,args=showHide.arguments;  for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];    if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v=='hide')?'hidden':v; }    obj.visibility=v; }}*/function showHide() { //mab: use wrapper className to preserve current section's menu's visibility  var i,p,v,obj,objs,args=showHide.arguments;  for (i=0; i<(args.length-1); i+=2) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+1];    if (obj.style) { objs=obj.style; v=(v=='show')?'visible':(v=='hide')?'hidden':v; }    if (obj.id != 'nav-'+MM_findObj('wrapper').className) { objs.visibility=v; } }}function jumpMenu(targ,selObj,restore){ //v3.0  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");  if (restore) selObj.selectedIndex=0;}function loadPage(topSection){	if (document.getElementById) {		highlightTop(topSection);		highlightSub(topSection);		//document.getElementById('wrapper').className = topSection; // capture topSection for use elsewhere	}	}function highlightTop(topSection){	if (document.getElementById) {		var topAnchorLi = document.getElementById(topSection);		if (topAnchorLi) {			var topAnchor = topAnchorLi.getElementsByTagName('a')[0];			if (topAnchor) {				topAnchor.className = 'here';				topAnchor.style.color = '#fff';			}		}	}}function highlightSub(topSection){	var thispath = window.location.toString().split('#')[0].split('?')[0];	if (document.getElementById) {		var navul = document.getElementById('nav-' + topSection);		if (navul) {			navul.style.visibility = 'visible';			navul.style.classname = 'topsection';			var navanchors = navul.getElementsByTagName('a');			if (navanchors) {				for(var i = 0; i <= navanchors.length-1; i++) {					if (navanchors[i].href == thispath) {						navanchors[i].className = 'select';						break;					}				}			}		}	}}function highlightThisProject() {	var thispath = window.location.toString().split('#')[0].split('?')[0];	thispath = thispath.replace(/http:\/\/(.+?)\//,'/');	thispath = thispath.replace('index.shtml','');		if (document.getElementById) {		var switcher = document.getElementById("switcher");		if (switcher) {			var switcherlinks = switcher.getElementsByTagName('option');			if (switcherlinks) {				for(var i = 0; i <= switcherlinks.length-1; i++) {					if (switcherlinks[i].value == thispath) {						switcherlinks[i].selected = 'selected';					}				}			}		}	}}function nextProject() {	var thispath = window.location.toString().split('#')[0].split('?')[0];	thispath = thispath.replace(/http:\/\/(.+?)\//,'/');	thispath = thispath.replace('index.shtml','');		if (document.getElementById) {	var switcher = document.getElementById("switcher");		if (switcher) {			var switcherlinks = switcher.getElementsByTagName('option');			if (switcherlinks) {				for(var i = 0; i <= switcherlinks.length-1; i++) {					if (switcherlinks[i].value == thispath) {						var jumplink = '/';						if (i == switcherlinks.length - 1) { 							jumplink = switcherlinks[2].value; // wrap around to beginning (skip first two items)						} else {							jumplink = switcherlinks[i + 1].value;						}						document.location = jumplink;					}				}			}		}	}}function prevProject() {	var thispath = window.location.toString().split('#')[0].split('?')[0];	thispath = thispath.replace(/http:\/\/(.+?)\//,'/');	thispath = thispath.replace('index.shtml','');		if (document.getElementById) {		var switcher = document.getElementById("switcher");		if (switcher) {			var switcherlinks = switcher.getElementsByTagName('option');			if (switcherlinks) {				for(var i = 0; i <= switcherlinks.length-1; i++) {					if (switcherlinks[i].value == thispath) {						var jumplink = '/';						if (i == 2) {  // don't consider first two items							jumplink = switcherlinks[switcherlinks.length - 1].value; // wrap around to end						} else {							jumplink = switcherlinks[i - 1].value; // wrap around to beginning						}						document.location = jumplink;					}				}			}		}	}}