var DHTML = (document.getElementById || document.all || document.layers);function setVisibility(vObject,vHideShow){	if (!DHTML) return;	var x = new getObj(vObject);	if(vHideShow=='hide')		{		x.style.visibility =  'hidden'		x.style.display = 'none'				}	else		{		x.style.visibility ='visible'		x.style.display = 'block'		}}function toggleVisibility(vObject){	if (!DHTML) return;	var x = new getObj(vObject);	if(x.style.visibility=='visible')		{		x.style.visibility =  'hidden'		x.style.display = 'none'				}	else		{		x.style.visibility ='visible'		x.style.display = 'block'		}}function getObj(name){  if (document.getElementById)  {   this.obj = document.getElementById(name); this.style = document.getElementById(name).style;  }  else if (document.all)  { this.obj = document.all[name]; this.style = document.all[name].style;  }  else if (document.layers)  {    this.obj = document.layers[name];    this.style = document.layers[name];  } } function getSLaddress(){		var vCategory=replaceSubstring(vDocument["Category"]," ","+")		var vDb=replaceSubstring(vDocument["Database"]," ","+")		var vSubject=replaceSubstring(vDocument["Subject"]," ","+")		var vType=replaceSubstring(vDocument["Type"]," ","+")		/////	vAddress2="_" + replaceSubstring(vAddress2," ","+")		var vSLaddress =vDb + "/Get" + vType + "/" + vCategory + "_"+ vSubject 		return vSLaddress}function openAddress(vAddress,vAddress2){//	f = document.forms[0];	var vServerName= vDocument["Server"]			var vAddress3	if( vServerName=='localhostXX')		{		//var vCategory=document.forms[0].daCategory.value		//var vDb=document.forms[0].daDb.value		//var vSubject=document.forms[0].daSubject.value		//var vType=document.forms[0].daType.value		vAddress2=replaceSubstring(vAddress2," ","+")			//	vAddress3="/" + vDb + "/Get" + vType + "/" + vCategory + "_"+ vSubject + "_" + vAddress2		var vSLcurrent = getSLaddress()		vAddress3="/" + vSLcurrent + "_" + vAddress2//		vAddress3=replaceSubstring(vAddress3," ","+")		//alert(unescape(vAddress2))		}		else		{	//	vAddress2=replaceSubstring(vAddress2,"&","and")		vAddress2=replaceSubstring(vAddress2," ","")		vAddress2='#'+ vAddress2		var vEnd=inStr(vAddress,'#')				var vAddressTemp=left(vAddress,vEnd)		if (vAddressTemp=="")			{			 vAddress3=vAddress + vAddress2			}		else			{			vAddress3=vAddressTemp + vAddress2			}		}window.location=vAddress3}var skipcycle = falsefunction focOnDialog(){if(!skipcycle){	window.focus();		}popopen =  setTimeout('focOnDialog()', 500);}function focOnMaint(){if(!skipcycle){	window.focus();		}popopen =  setTimeout('focOnDialog()', 500);}function ShowDialog(vAddress,vName,vWidth,vHeight){if (typeof vWidth=="undefined")	{vWidth="900"}if (typeof vHeight=="undefined")	{vHeight="600"}var vParameters ="width=" + vWidth + ",height=" + vHeight + ",left=80,top=80,scrollbars=yes,resizable=yes,titlebar=0"window.open(vAddress,vName,vParameters)} function createCookie(name,value,days) {	if (days) {		var date = new Date();		date.setTime(date.getTime()+(days*24*60*60*1000));		var expires = "; expires="+date.toGMTString();	}	else var expires = "";	document.cookie = name+"="+value+expires+"; path=/";}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 eraseCookie(name) {	createCookie(name,"",-1);}// End JS Header - theBrowserContentfunction setCustomerCookie(){	var f = document.forms[0];	var vOption	for (var i=0; i<f.CustomerSelect.length; i++)		{			{if (f.CustomerSelect[i].selected)				{vOption=f.CustomerSelect[i].text}			}		}//		var vCookie = 		setCookie("Customer",vOption,24)		history.go()}function setCookie(name, value, expiryhour, path, domain, secure) {expiry=1000 * 60 * (60 * expiryhour);var the_date = new Date();the_date.setTime (the_date.getTime() + expiry);var the_cookie_date = the_date.toGMTString();var curCookie = name + "=" + escape(value) +";expires=" + the_cookie_date + ((path) ? "; path=" + path : "") +((domain) ? "; domain=" + domain : "") +((secure) ? "; secure" : "");document.cookie = curCookie;}// name - name of the desired cookie// * return string containing value of specified cookie or null if cookie does not existfunction getCookie(name) {var dc = document.cookie;var prefix = name + "=";var begin = dc.indexOf("; " + prefix);if (begin == -1) {begin = dc.indexOf(prefix);if (begin != 0) return null;} elsebegin += 2;var end = document.cookie.indexOf(";", begin);if (end == -1)end = dc.length;return unescape(dc.substring(begin + prefix.length, end));}// name - name of the cookie// [path] - path of the cookie (must be same as path used to create cookie)// [domain] - domain of the cookie (must be same as domain used to create cookie)// * path and domain default if assigned null or omitted if no explicit argument proceedsfunction deleteCookie(name, path, domain) {if (getCookie(name)) {document.cookie = name + "=" + ((path) ? "; path=" + path : "") +((domain) ? "; domain=" + domain : "") +"; expires=Thu, 01-Jan-70 00:00:01 GMT";}} function roll(img_name, img_src,img_align,img_width,img_height,img_border,img_hspace,img_vspace)   {   var sizeImage= new Image(); sizeImage.src=img_src; var f=document.forms[0]f.document[img_name].src=img_src;alert(img_name)f.document[img_name].align=img_alignif(img_width==0)	{f.document[img_name].width =sizeImage.width;}else	{f.document[img_name].width =img_width;}if(img_height==0)	{f.document[img_name].height =sizeImage.height;}else	{f.document[img_name].height =img_height;}		if(img_border==0)	{f.document[img_name].border=sizeImage.border;}else	{f.document[img_name].border=img_border;}	if(img_hspace==0)	{f.document[img_name].hspace=sizeImage.hspace;}else	{f.document[img_name].hspace=img_hspace;}	if(img_vspace==0)	{f.document[img_name].vspace=sizeImage.vspace;}else	{f.document[img_name].vspace=img_vspace;}		//  top.body.document[img_name].height = "60";   }function viewListTools(vLevel){if (typeof vLevel=="undefined")	{vLevel="Child"}		f = document.forms[0];var vDocId = vDocument["DocumentId"]var vDb=vDocument["Database"]//	var vCategory = document.forms[0].daCategory.value//		var vSubject = document.forms[0].daSubject.value//				var vType = document.forms[0].daType.value//	if(vType==vCategory)//	{vCategory=vSubject}//	else//		{vCategory=vCategory + "_" + vSubject}//			alert(escape(vCategory))//	vCategory=vType+"_"+vCategory	var vAddress	var vCategory		if (vLevel=="Parent")		{if (vDocument["Category"].indexOf('_')==-1)			{			vCategory= vDocument["Category"]			if(vDocument["Type"]==vCategory)				{				vAddress='/' + vDb + '/0/' + vDocId + '?opendocument&Subform=theNavigatorEdit&Layout=' + vDocument["Layout"] + '&Category=' + vCategory + '&Type=' + vCategory				}			else				{				vCategory=  vDocument["Category"]				//vCategory= vDocument["Type"] + '_' + vDocument["Category"]				vAddress='/' + vDb + '/get' +vDocument["Type"]+ '/' +vCategory + '?opendocument&Subform=theNavigatorEdit'									}			}		else			{			vCategory= vDocument["Category"]			vAddress='/' + vDb + '/get' +vDocument["Type"] + '/' +vCategory + '?opendocument&Subform=theNavigatorEdit'				}					}	else			{vAddress='/' + vDb + '/0/' + vDocId + '?opendocument&Subform=theNavigatorEdit'}	location.href= vAddress	}function viewCurrentCategoryX(){//to be replaced with viewListTools	f = document.forms[0];var vDocId = vDocument["DocumentId"]var vDb=vDocument["Database"]//	var vCategory = document.forms[0].daCategory.value//		var vSubject = document.forms[0].daSubject.value//				var vType = document.forms[0].daType.value//	if(vType==vCategory)//	{vCategory=vSubject}//	else//		{vCategory=vCategory + "_" + vSubject}//			alert(escape(vCategory))//	vCategory=vType+"_"+vCategory	var vAddress	vAddress='/' + vDb + '/0/' + vDocId + '?opendocument&Subform=theNavigatorEdit'	location.href= vAddress	}function viewCategory(vType){//to be replaced with viewListToolsf = document.forms[0];var vDocId = vDocument["DocumentId"]var vDb=vDocument["Database"]//if(vDocument["Subject"]==vDocument["Layout"])//	{alert('layout')}//	var vCategory = document.forms[0].daCategory.value//		var vSubject = document.forms[0].daSubject.value//				var vType = document.forms[0].daType.value//	if(vType==vCategory)//	{vCategory=vSubject}//	else//		{vCategory=vCategory + "_" + vSubject}//			alert(escape(vCategory))//	vCategory=vType+"_"+vCategory	var vAddress//	vAddress='/' + vDb + '/0/' + vDocId + '?opendocument&Subform=theNavigatorEdit&Navigator=' + vType	vAddress='/' + vDb + '/get/' + vDocId + '?opendocument&Subform=theNavigatorEdit&Navigator=' + vType//location.replace(vAddress)//prompt("xxx",vAddress)location.href= vAddress		//window.location=vAddress	//window.location.href=vAddress//	ShowDialog(vAddress,"Application",600,400);//top.location.href=vAddress//self.location.href=vAddress}function editDocument(vParameters){var vAddress//var vSubformvar vDb=vDocument["Database"]var vDocId = vDocument["DocumentId"]vAddress =  "/" + vDb + "/theLookupByDocumentId/" + vDocIdvAddress+="?editDocument" + vParameterslocation.href= vAddress	}function newDocument(vType,vParameters){var vAddressvar vDb=vDocument["Database"]var vDocId = vDocument["DocumentId"]var vLayout = vDocument["Layout"]var vFormif (vType=='Response')	{	vForm='theFormResponse'	vType="Sibling"	}	else	{	vForm='theForm'		}	// New document added to current list, if it exist	if(vType=='List'| vType=='Child')	{if(vDocument["ListCategory"]=='' | typeof vDocument["ListCategory"]=='undefined')		{		if(vDocument["Type"]==vDocument["Category"])			{vCategory = escape(vDocument["Subject"])}		else			{vCategory = escape(vDocument["Category"])}						     vSubject = escape(vDocument["Subject"])			}		else		{		var vUnderscore = inStr(vDocument["ListCategory"],'_')		var vLength = len(vDocument["ListCategory"])		vCategory =escape(vDocument["ListCategory"])		var vRight=vLength - vUnderscore-1		vSubject=right(vDocument["ListCategory"],vRight)    		}	}else if(vType=='Root')		{	if(vDocument["Type"]==vDocument["Category"])		{vCategory = escape(vDocument["Category"])		}	else		{vCategory = escape(vDocument["Category"])		}				vSubject = escape(vDocument["Subject"])	}else	{		if(vDocument["Type"]==vDocument["Category"])		{vCategory = escape(vDocument["Subject"])}	else		{vCategory = escape(vDocument["Category"])}				vSubject = escape(vDocument["Subject"])		}	//vAddress =  "/" + vDb + "/theForm?OpenForm&ParentUNID=" + vDocId  + "&Subject=" + vSubject + "&Category=" + vCategory + "&Layout=" + vLayout      //vAddress+= "&Subform=" + vSubformEdit+ "&BodyStyle=" + vBodyStyle	//vAddress +=  "&BodyEdit=" + vBodyEdit	vAddress =  "/" + vDb + "/" + vForm + "?OpenForm&ParentUNID=" + vDocId  + "&Subject=" + vSubject + "&Category=" + vCategory + "&Layout=" + vLayout 	vAddress= vAddress + vParameters	location.href= vAddress	}function editDocumentX(vSubformEdit,vField){var vAddress//var vSubformvar vDb=vDocument["Database"]	f = document.forms[0];var vSubject = vDocument["Subject"]var vDocId = vDocument["DocumentId"]if (typeof vSubformEdit=='undefined')	{vSubformEdit="&Subform=" + vDocument["Subform"]}else	{vSubformEdit="&Subform=" + vSubformEdit}//var vBody = vDocument["Subform"]if (typeof vField=='undefined')	{vField=""}else	{vField="&Field=" + vField}vAddress =  "/" + vDb + "/theLookupByDocumentId/" + vDocIdvAddress+="?editDocument" + vSubformEdit + vField//vAddress =  vAddress + vSuffixlocation.href= vAddress	}//http://localhost/theSourceTesting.nsf/getbody/Player-Fields_LastNameX?editdocument&NotFound=theFieldsNewfunction editField(vSubformEdit,vField){var vAddress//var vSubformvar vDb=vDocument["Database"]	f = document.forms[0];var vSubject = vDocument["Subject"]//var vDocId = vDocument["DocumentId"]//if (typeof vSubformEdit=='undefined')//	{vSubformEdit="&Subform=" + vDocument["Subform"]}//else//	{vSubformEdit="&Subform=" + vSubformEdit}//var vBody = vDocument["Subform"]//if (typeof vField=='undefined')//	{vField=""}//else//	{vField="&Field=" + vField}vAddress =  "/" + vDb + "/getbody/" + vSubformEdit + "-Fields_" + vField + "?editdocument&NotFound=theFieldsNew"//vAddress+="?editDocument" + vSubformEdit + vField//vAddress =  vAddress + vSuffixlocation.href= vAddress	}function processEdit(vType,vField,vSwitchBodyStyle){var vAddress//var vSubformvar vDb=vDocument["Database"]if (typeof vField=='undefined')	{vField=""}else	{vField="&Field=" + vField}	if (typeof vSwitchBodyStyle=='undefined')	{vSwitchBodyStyle=""}else if (vSwitchBodyStyle=='Promote')	{if (vDocument["PromoteTo"]=='')		{vSwitchBodyStyle=""}	else		{vSwitchBodyStyle="&BodyStyle=" +vDocument["PromoteTo"]}		}else	{vSwitchBodyStyle="&BodyStyle=" + vSwitchBodyStyle}			f = document.forms[0];var vSubject = vDocument["Subject"]var vDocId = vDocument["DocumentId"]var vBody = vDocument["Subform"]var vSuffixvAddress =  "/" + vDb + "/theLookupByDocumentId/" + vDocId	if(vType=="Standard")   {   vSuffix="?editDocument&Subform=theContentEdit&" + vField + vSwitchBodyStyle    vAddress =  vAddress + vSuffix   }//else if(vType=="PRIMARY")//   {// vAddress =  "/" + vDocument["LayoutDb"]+ "/GetLayout/Layout_" + vDocument["Layout"] + "!opendocument&Subform=theNavigatorEdit&Navigator=Primary"//   }   else if(vType=="PRIMARY")   { vAddress =  "/" + vDb + '/get/' + vDocId + '!opendocument&Subform=theNavigatorEdit&Layout=' + vDocument["Layout"]  + '&NavCategory=' + vDocument["PrimaryNav"]   + '&Navigator=Primary' 	}   else if(vType=="CHILD")   { vAddress =  "/" + vDb + '/get/' + vDocId + '!opendocument&Subform=theNavigatorEdit&Layout=' + vDocument["Layout"]  + '&NavCategory=' + vDocument["ChildNav"]  + '&Navigator=Child'   }   else if(vType=="SIBLING")   { vAddress =  "/" + vDb + '/get/' + vDocId + '!opendocument&Subform=theNavigatorEdit&Layout=' + vDocument["Layout"]  + '&NavCategory=' + vDocument["SiblingNav"]  + '&Navigator=Sibling'   }      else if(vType=="SECONDARY")   { vAddress =  "/" + vDb + '/get/' + vDocId + '!opendocument&Subform=theNavigatorEdit&Layout=' + vDocument["Layout"]  + '&NavCategory=' + vDocument["SecondaryNav"]  + '&Navigator=Secondary'   }   //else if(vType=="SECONDARY")//   {// vAddress =  "/" + vDocument["LayoutDb"]+ "/GetLayout/Layout_" + vDocument["Layout"] + "!opendocument&Subform=theNavigatorEdit&Navigator=Secondary" //  }//           else if(vType=="SIBLING")//   {            //viewCategory('Sibling')//            	vAddress='/' + vDb + '/get/' + vDocId + '?opendocument&Subform=theNavigatorEdit&Navigator=' + vType//   } //            else if(vType=="CHILDREN") //  {//            	vAddress='/' + vDb + '/get/' + vDocId + '?opendocument&Subform=theNavigatorEdit&Navigator=' + vType//   }              else if(vType=="Layout")   { vAddress =  "/" + vDocument["LayoutDb"]+ "/GetLayout/Layout_" + vDocument["Layout"] + "!opendocument&Subform=theLayoutParameters"   }             else if(vType=="Body")   {  		 if (vBody=="Content_ListLeft" |vBody=="Content_ListRight")   			{vBody="Content"} 		vAddress =  "/" + vDocument["LayoutDb"]+ "/GetResource/Body_" + vBody + "!editdocument&Subform=BodySettings"   }              else if(vType=="Body")   { 		alert("Logic removed. See ProcessEditX to recover logic")   }   else if(vType=="Link")   {    vSuffix="?editDocument&Subform=theContentEditTab&Tabs=YNHHN&BodyEdit=theLinkCommon"//      vSuffix="?editDocument&Subform=LinkEdit&LinkType=" + replaceSubstring(vField,' ','+')    vAddress =  vAddress + vSuffix   }         else if(vType=="Cancel")   {    vAddress="javascript:history.back()"   }   else if(vType=="Delete" | vType=="Rename")	{		vAddress =  "/" + vDb + "/theFormBody?readform&Subform=theWebAgentHTML&Print=Yes&Modal=Yes&Action=" + vType + "&DocumentId=" + vDocId				vAddress +=   "&Subject=" + vSubject//	vAddress =  "/" + vDb + "/theFormBody?readform&Subform=theWebAgentHTML&Print=Yes&Modal=Yes&Action=" + vType + "&DocumentId=" + vDocId		ShowDialog(vAddress,"Application",600,400);	return//var newWindow = window.showModalDialog(vAddress, window);	}else if(vType=="New")	{ 		alert("Logic removed. See ProcessEditX to recover logic")	}     else   {//alert('Edit processing is not supported for ' + vType)  //    vSuffix="?editDocument&Subform=" + vType + vField//    vAddress =  vAddress + vSuffixvar vTabsvar vBodyEdit=""var vListSettingif (vDocument["Category"]==vDocument["Type"])	{vListSetting="H"}else	{vListSetting="N"}	if (vDocument["BodyStyle"]=="ListOnly" | vDocument["BodyStyle"]=="Link")	{vTabs="NYHHN"	vBodyEdit="&BodyEdit=theEditListOnly&SourceId=" + vDocId	}	else if (vField=="&Field=theSecondary")	{vTabs="N" + vListSetting + "NYH"}	else	{vTabs="N" + vListSetting + "YNH"}	      vSuffix="?editDocument&Subform=" + vType + "Tab"    vAddress =  vAddress + vSuffix + "&Tabs=" + vTabs + vBodyEdit    }	//vAddress=vAddress +"&Subform=Body-BasicEdit"location.href= vAddress	}function processEditX(vType,vField,vSwitchBodyStyle){var vAddress//var vSubformvar vDb=vDocument["Database"]if (vField=='undefined')	{vField=""}else	{vField="Field=" + vField}	if (typeof vSwitchBodyStyle=='undefined')	{vSwitchBodyStyle=""}else if (vSwitchBodyStyle=='Promote')	{if (vDocument["PromoteTo"]=='')		{vSwitchBodyStyle=""}	else		{vSwitchBodyStyle="&BodyStyle=" +vDocument["PromoteTo"]}		}else	{vSwitchBodyStyle="&BodyStyle=" + vSwitchBodyStyle}			f = document.forms[0];var vSubject = vDocument["Subject"]var vDocId = vDocument["DocumentId"]var vBody = vDocument["Subform"]var vSuffixvAddress =  "/" + vDb + "/theLookupByDocumentId/" + vDocId	if(vType=="PrimaryX")   {   	vSuffix= "?editDocument&Subform=Body-PrimaryEdit "   		vAddress =  vAddress + vSuffix  	}  	   else if(vType=="Standard")   {   vSuffix="?editDocument&Subform=theContentEdit&" + vField + vSwitchBodyStyle    vAddress =  vAddress + vSuffix   }     	   else if(vType=="RichText")   {//   vSuffix="?editDocument&Subform=theRichTextEdit&Field=" + vField + vSwitchBodyStyle      vSuffix="?editDocument&Subform=theBasic&BodyEdit=theRichTextEdit"    vAddress =  vAddress + vSuffix   }  //   	   else if(vType=="Body")//   {//   vSuffix="?editDocument&Subform=Body&Field=" + vField + vSwitchBodyStyle //   vAddress =  vAddress + vSuffix//   }      	   else if(vType=="Definition")   {   vSuffix="?editDocument&Subform=Definition&Field=" + vField + vSwitchBodyStyle    vAddress =  vAddress + vSuffix   }       	   else if(vType=="RichText")   {   vSuffix="?editDocument&Subform=Body-RichTextEdit&Field=" + vField    vAddress =  vAddress + vSuffix   }     	   else if(vType=="RichText_1")   {   vSuffix="?editDocument&Subform=Body-RichTextEdit_1&Field=" + vField    vAddress =  vAddress + vSuffix   }     	   else if(vType=="Advanced")   {   vSuffix="?editDocument&Subform=theSettingsAdvanced&Field=" + vField    vAddress =  vAddress + vSuffix   }   else if(vType=="Secondary")   {   vSuffix="?editDocument&Subform=Body-SecondaryEdit"    vAddress =  vAddress + vSuffix   }      else if(vType=="Primary Navigator")   { vAddress =  "/" + vDocument["LayoutDb"]+ "/GetLayout/Layout_" + vDocument["Layout"] + "!opendocument&Subform=theNavigatorEdit&Navigator=Primary"   }         else if(vType=="Secondary Navigator")   { vAddress =  "/" + vDocument["LayoutDb"]+ "/GetLayout/Layout_" + vDocument["Layout"] + "!opendocument&Subform=theNavigatorEdit&Navigator=Secondary"   }            else if(vType=="Layout")   { vAddress =  "/" + vDocument["LayoutDb"]+ "/GetLayout/Layout_" + vDocument["Layout"] + "!opendocument&Subform=theLayoutParameters"   }               else if(vType=="Body")   {   var vBody =leftBack(vDocument["Subform"],'_')   if (vBody=='')   	{vBody=vDocument["Subform"]}   	 vAddress =  "/" + vDocument["LayoutDb"]+ "/GetLayout/Body_" + vBody + "!opendocument&Subform=theBodyEdit&Layout=" + vDocument["Layout"]  + "&DocumentId=" + vDocument["DocumentId"]    }   else if(vType=="Edit")   {   vSuffix="?editDocument"    vAddress =  vAddress + vSuffix   }   else if(vType=="Summary")   {   vSuffix="?editDocument&Subform=Body-SummaryEdit"    vAddress =  vAddress + vSuffix   }    else if(vType=="List")   {   vSuffix="?editDocument&Subform=theListEdit"    vAddress =  vAddress + vSuffix   }    else if(vType=="Link")   {    vSuffix="?editDocument&Subform=theBasic&BodyEdit=theLinkEdit"//      vSuffix="?editDocument&Subform=LinkEdit&LinkType=" + replaceSubstring(vField,' ','+')    vAddress =  vAddress + vSuffix   }      	   else if(vType=="Blog")   {   vSuffix="?editDocument&Subform=Body-BlogEdit"    vAddress =  vAddress + vSuffix   }     else if(vType=="PrimaryGraphic")   {//   	vAddress =  "/" + vDb + "/theLookupByDocumentId/" + vDocId + "?openDocument";	vSuffix= "?openDocument&Subform=Body-Basic+Graphic"; //  vSuffix="?editDocument&Subform=Body-SecondaryEdit"    vAddress =  vAddress + vSuffix    processGraphic()    return;   }      else if(vType=="Cancel")   {    vAddress="javascript:history.back()"   }         else if(vType=="Delete" | vType=="Rename")	{//	vAddress =  "/" + vDb + "/theSystem-External+HTML" + "?readform&Action=Delete&DocumentId=" + vDocId		vAddress =  "/" + vDb + "/theFormSubform?readform&Subform=theWebAgentHTML&Print=Yes&Modal=Yes&Action=" + vType + "&DocumentId=" + vDocId				vAddress +=   "&Subject=" + vSubject// 	vAddress = vAddress + "&ExternalAgent=WebDialog"ShowDialog(vAddress,"Application",600,400);	return//var newWindow = window.showModalDialog(vAddress, window);	}else if(vType=="New")	{//	vDocId = document.forms[0].daDocumentId.value//	vAddress =  "/" + vDb + "/theForm?OpenForm&ParentUNID=" + vDocId + "&Print=Yes&Modal=Yes&Subform=theDialogNew"	vAddress =  "/" + vDb + "/theDialogNew?OpenForm&ParentUNID=" + vDocId + "&Modal=Yes&Subform=theContentEdit"		vAddress +=  "&SubformEdit=theContentEditEdit&FamilyType=Child"	//ShowDialog(vAddress,"Application",500,500);	 	var vParameters ="width=500,height=400,left=80,top=80,scrollbars=no,resizable=yes"	window.open(vAddress,"Application",vParameters)	return	}      else if(vType=="NewBlog")	{//	vDocId = document.forms[0].daDocumentId.value//vAddress =  "/" + vDb + "/theForm?OpenForm&ParentUNID=" + vDocId + "&Print=Yes&Modal=Yes&Subform=theDialogNew"//	var vParameters ="width=500,height=400,left=80,top=80,scrollbars=no,resizable=yes"//	window.open(vAddress,"Application",vParameters)	//	return		 vAddress =  "/" + vDocument["Database"] + "/WebCreateNew?OpenAgent&Action=CreateSibling&UNID=" + vDocId + "&Subject=" + 'change me'+  "&Subform=Body-BlogEdit";	 	vAddress=vAddress + "&Description=" + 'change me'	 		}  else   {//alert('Edit processing is not supported for ' + vType)      vSuffix="?editDocument&Subform=" + vType + vField    vAddress =  vAddress + vSuffix    }	//vAddress=vAddress +"&Subform=Body-BasicEdit"location.href= vAddress	}var skipcycle = falsefunction focOnDialog(){if(!skipcycle){	window.focus();		}popopen =  setTimeout('focOnDialog()', 500);}function focOnMaint(){if(!skipcycle){	window.focus();		}popopen =  setTimeout('focOnDialog()', 500);}// End JS Header - theBrowserContentfunction setCustomerCookie(){	var f = document.forms[0];	var vOption	for (var i=0; i<f.CustomerSelect.length; i++)		{			{if (f.CustomerSelect[i].selected)				{vOption=f.CustomerSelect[i].text}			}		}//		var vCookie = 		setCookie("Customer",vOption,24)		history.go()}function setCookie(name, value, expiryhour, path, domain, secure) {expiry=1000 * 60 * (60 * expiryhour);var the_date = new Date();the_date.setTime (the_date.getTime() + expiry);var the_cookie_date = the_date.toGMTString();var curCookie = name + "=" + escape(value) +";expires=" + the_cookie_date + ((path) ? "; path=" + path : "") +((domain) ? "; domain=" + domain : "") +((secure) ? "; secure" : "");document.cookie = curCookie;}// name - name of the desired cookie// * return string containing value of specified cookie or null if cookie does not existfunction getCookie(name) {var dc = document.cookie;var prefix = name + "=";var begin = dc.indexOf("; " + prefix);if (begin == -1) {begin = dc.indexOf(prefix);if (begin != 0) return null;} elsebegin += 2;var end = document.cookie.indexOf(";", begin);if (end == -1)end = dc.length;return unescape(dc.substring(begin + prefix.length, end));}// name - name of the cookie// [path] - path of the cookie (must be same as path used to create cookie)// [domain] - domain of the cookie (must be same as domain used to create cookie)// * path and domain default if assigned null or omitted if no explicit argument proceedsfunction deleteCookie(name, path, domain) {if (getCookie(name)) {document.cookie = name + "=" + ((path) ? "; path=" + path : "") +((domain) ? "; domain=" + domain : "") +"; expires=Thu, 01-Jan-70 00:00:01 GMT";}} function processGraphic(vGraphic,vDocId){//http://localhost/theSourceTesting.nsf/theAttachmentPopup?openform&Modal=No&Parameter=list@DDAAC2F0B11774F5862570AE004D06CB@spacer@BruceFahlen.jpg@Yes@240@195@center@0@0@0@Basic@theSourceTesting.nsf@theSourceTesting.nsfvar f=document.forms[0]//var vDocumentId=vDocument["DocumentId"];if(vGraphic=="summary")	{var vGraphicName=vGraphic+ vDocId}else if(vGraphic=="list")	{var vGraphicName=vGraphic+ vDocId}else if(vGraphic=="pb")	{var vGraphicName=vGraphic+vDocId}else		{var vGraphicName=vGraphic+ vDocId}//if(typeof vType=="undefined")//vGraphicName="listTest"//vGraphicName="primaryDDAAC2F0B11774F5862570AE004D06CB"var vGroup=vDocument["Group"]if (vGroup=="")	{vGroup="Root"}var vServerName=vDocument["Server"]var vLocalDirectory=vDocument["LocalDirectory"]var vLocalSubdirectoryvar vServerAdjustmentif(vServerName=="localhost")	{vLocalSubdirectory="/" + vLocalDirectory	vServerAdjustment=0	}else	{vLocalSubDirectory=""	vServerAdjustment=1	}vServerName=vServerName +vLocalSubdirectoryvar vDb=vDocument["Database"]var vFlag//var vSourcevar vNamevar vDirectoryvar vStartvar vEndvar vLen//var vDocId = vDocument["DocumentId"]var vSrc//var vHeight//var vWidth//var vVspace//var vHspace//var vBordervar vAlignvar vAltvar vObject//vObject= f.document[vGraphicName]vObject= document.images[vGraphicName]if ( typeof vObject=='undefined')	{	vSrc='None'//	vHeight = 0//	vWidth = 0//	vVspace = 0//	vHspace = 0//	vBorder = 0	vAlign = 'left'	vAlt = ''	}	else	{vSrc= vObject.src//	vHeight = vObject.height//	vWidth = vObject.width//	vVspace = vObject.vspace//	vHspace = vObject.hspace//	vBorder = vObject.border	if(vObject.id=="imgFloatLeft")		{vAlign="left"}	else	if(vObject.id=="imgFloatRight")		{vAlign="right"}	else			{vAlign="center"}//vAlign = document.getElementById([vGraphicName]).align	//vAlt = f.document[vGraphicName].alt		vAlt = escape(vObject.alt)	}	vLen=len(vDocument["Server"])var vDatabasevStart=vSrc.indexOf(vDocument["Server"]) + vLen + 1vEnd=vSrc.indexOf('/Get') -vStart vDatabase=mid(vSrc,vStart, vEnd)if(vDatabase=="")	{vDatabase=vDb}//if(vBorder=='')//	{vBorder=0}if(vAlt=='')	{vAlt='None'}	//alert(document.getElementById("primaryGraphic").align)//if(document.getElementById("primaryGraphic").align=='center') //	{vAlign='center'}//elseif(vAlign=='')	{vAlign='center'}	var vAddressif (vGraphicName=='secondaryGraphic'  & typeof vObject=='undefined')	{		vFlag = "Yes"          	vAddress="/" + vDatabase+ '/theAttachmentPopup?openform'  //   	vSource='Image Directory'			     vName=''		vDirectory="Basic"	}	else if (vSrc.indexOf('?openimageresource')!=-1)	{		vFlag = "Yes"	     	vAddress="/" + vDatabase+ '/theAttachmentPopup?openform'     	vSource='Domino Image Resource'	}	else if (vSrc.indexOf('$file')!=-1)	{		vFlag = "Yes"			vAddress="/" + vDatabase + "/theAttachmentPopup?openform"//	   vAddress="/" + vDb + "/getResource/Image_" + vCat + "?editDocument"//	    vSource='Image Document'	    	vStart=vSrc.indexOf('Resource/Image_')+15		vEnd=vSrc.indexOf('/$file')-vStart	     vDirectory=mid(vSrc,vStart, vEnd)	     		     vName=(rightBack(vSrc,'/'))  	}		else if (vSrc.indexOf('icons/ecblank.gif')!=-1)	{		vFlag = "No"			vAddress="/" + vDb + "/theAttachmentPopup?openform"	//  vAddress="/" + vDb + "/getResource/Image_" + vCat + "?editDocument" //    	vSource='Image Document'	     vDirectory="Basic"	     vName=""	}     else	     {		vFlag = "Yes"          	vAddress="/" + vDb + '/theAttachmentPopup?openform'  //   	vSource='Image Directory'			     vName=(rightBack(vSrc,'/'))  //old	    	vStart=vSrc.indexOf(vServerName + "/")	    	vEnd=vSrc.indexOf('/'+ vName)			var vServerLength=vServerName.length		var vSrcLength=vSrc.length	//	vEnd=vSrc.indexOf('/$file')-vStart		vDirectory=mid(vSrc,vStart+vServerLength+1-vServerAdjustment, vEnd-vStart-vServerLength-1+vServerAdjustment)//new//	    	vStart=vSrc.indexOf(vServerName + "/")//	    	vStart=vSrc.indexOf("/"+ "/")//	    	vEnd=vSrc.indexOf('/'+ vName)	//		var vServerLength=vServerName.length//		var vSrcLength=vSrc.length//		vDirectory=right(vSrc,vSrcLength-18)//		vDirectory=mid(vDirectory,0,(vDirectory.length-vName.length-1))// new end		if(vDirectory=='')			{			vDirectory="Select+Image+Directory"			}     }// if graphic address is same as document address set Directory to Current Document		var vSLaddress = getSLaddress()	     	     if(vSLaddress==vDirectory)	     	{vDirectory="Current Document"}	     	if(vDirectory=='')	{vDirectory='None'}if(vName=='')	{vName='None'} else if (vName.indexOf('!')!=-1)	{vName=mid(vName,0,vName.indexOf('!'))}	if(leftBack(vDirectory,"_")==vGroup)	{vDirectory=rightBack(vDirectory,"_")}   	//vAddress="/" + vDb + "/getResource/Image_" + vCat + "?editDocument&Print=Yes" + "&Modal=Yes&Parameter=" 	vAddress=vAddress +"&Modal=No&Parameter=" //	vAddress= vAddress + vGraphic + "@" + vDocId + "@" + vAlt + "@" + escape(vName) + "@" + vFlag + "@" + vHeight + "@" + vWidth+   "@" + vAlign//	vAddress=vAddress  + "@" + vVspace + "@" + vHspace + "@" + vBorder  +   "@" + vDirectory+   "@" + vDatabase + "@" + vDb	vAddress= vAddress + vGraphic + "@" + vDocId + "@" + vAlt + "@" + escape(vName) + "@" + vFlag + "@"  + vAlign	vAddress=vAddress  + "@" + vDirectory+ "@" + vGroup+   "@" + vDatabase + "@" + vDb	//window.open(vAddress, "GraphicDialog");ShowDialog(vAddress,"Graphics",550,500)//var vParameters ="width=550,height=500,left=80,top=80,scrollbars=yes,resizable=yes"//var graphicWin=window.open(vAddress,"Graphics",vParameters)//alert(graphicWin.location.href + vAddress2)//graphicWin.location.replace(graphicWin.location.href + vAddress2)//window.open(location.href +vAddress2,"Graphics",vParameters)	}function processGraphicAdd(vGraphic,vWindow){var vFormif(vGraphic=='Image')	{vForm='theAttachmentStore'}else if(vGraphic=='PDF')	{vForm='theAttachmentPDF'}else	{vForm='theAttachmentAdd'}//var vDb=vDocument["Database"]var vDb=vDocument["Database"]var vMsg =escape("Select the desired database, directory, and graphic.<br>Click apply to add.")var vAddress="/" + vDb + '/' + vForm + '?openform'vAddress=vAddress +"&Modal=No&Graphic=" + vGraphic+ "&Message="  + vMsg //vAddress=vAddress  + "&Directory=Basic"+ "&Group=" +vDocument["Group"] +"&Database=" + vDbvAddress=vAddress  + "&Group=" +vDocument["Group"] +"&Database=" + vDbif (typeof vWindow=="undefined")	{window.location=vAddress}else if(vWindow=="")	{window.location=vAddress}else		{ShowDialog(vAddress,"Graphics",600,500)}}		function processAttachAddFromEdit(vAttachType,vField,vGroup,vWindow){	var f=document.forms[0];	var vDirectory	vDirectory=escape(getValue(f,vField) )if(vField!='theDirectory')	{	f[vField].selectedIndex=0	}	processAttachAdd(vAttachType,vDirectory,vGroup,vWindow)}	function processAttachAdd(vAttachType,vDirectory,vGroup,vWindow){var f=document.forms[0];var vForm="theAttachAdd"//if(vAttachType=='Image')//	{vForm='theAttachAdd'}//else if(vAttachType=='PDF')//	{vForm='theAttachAdd'}//else//	{vForm='theAttachAdd'}var vDb=vDocument["Database"]var vAddressif(vDocument["Server"]=="localhost" | vAttachType=="PDF")	{	vForm=vForm + "Local"	vAddress="/" + vDb + '/' + vForm + '?openform'	vAddress=vAddress +"&Modal=No&Graphic=" + vAttachType	vAddress=vAddress  + "&Directory="+ vDirectory+ "&Group=" +vGroup+"&Database=" + vDb + "&Resource=" +vAttachType+ "&Layout=" +vDocument['Layout']	}	else	{	vAddress="/" + vDb + '/' + vForm + '?openform'	vAddress=vAddress +"&Modal=No&Graphic=" + vAttachType	vAddress=vAddress  + "&Directory="+ vDirectory+ "&Group=" +vGroup+"&Database=" + vDb + "&Resource=" +vAttachType+ "&Layout=" +vDocument['Layout']	}if (typeof vWindow=="undefined")	{window.location=vAddress}else if(vWindow=="")	{window.location=vAddress}else		{ShowDialog(vAddress,"Graphics",650,500)}}		function rollX(img_name, img_src,img_align,img_width,img_height,img_border,img_hspace,img_vspace)   {   var sizeImage= new Image(); sizeImage.src=img_src; var f=document.forms[0]f.document[img_name].src=img_src;f.document[img_name].align=img_alignif(img_width==0)	{f.document[img_name].width =sizeImage.width;}else	{f.document[img_name].width =img_width;}if(img_height==0)	{f.document[img_name].height =sizeImage.height;}else	{f.document[img_name].height =img_height;}		if(img_border==0)	{f.document[img_name].border=sizeImage.border;}else	{f.document[img_name].border=img_border;}	if(img_hspace==0)	{f.document[img_name].hspace=sizeImage.hspace;}else	{f.document[img_name].hspace=img_hspace;}	if(img_vspace==0)	{f.document[img_name].vspace=sizeImage.vspace;}else	{f.document[img_name].vspace=img_vspace;}		//  top.body.document[img_name].height = "60";   }function viewCurrentCategory(){//	f = document.forms[0];var vDocId = vDocument["DocumentId"]var vDb=vDocument["Database"]//	var vCategory = document.forms[0].daCategory.value//		var vSubject = document.forms[0].daSubject.value//				var vType = document.forms[0].daType.value//	if(vType==vCategory)//	{vCategory=vSubject}//	else//		{vCategory=vCategory + "_" + vSubject}//			alert(escape(vCategory))//	vCategory=vType+"_"+vCategory	var vAddress	vAddress='/' + vDb + '/0/' + vDocId + '?opendocument&Subform=theNavigatorEdit'	location.href= vAddress	}function createNewOld(vFamilyType,vSubformNew,vSubformEdit){if(typeof vFamilyType=='undefined')	{vFamilyType="Both"}if(typeof vSubformNew=='undefined')	{vSubformNew=""}	if(typeof vSubformEdit=='undefined')	{vSubformEdit=""}	var vAddressvar vDb=vDocument["Database"]f = document.forms[0];var vDocId = vDocument["DocumentId"]vAddress =  "/" + vDb + "/theDialogNew?OpenForm&ParentUNID=" + vDocId + "&Modal=Yes&Subform=" + vSubformNewvAddress +=  "&SubformEdit=" + vSubformEdit + "&FamilyType=" + vFamilyType	//ShowDialog(vAddress,"Application",500,500);	 var vParameters ="width=500,height=400,left=80,top=80,scrollbars=no,resizable=yes"window.open(vAddress,"Application",vParameters)return}function createNewNotUsed(vForm,vEditSubform,vBodyStyle,vType){//if(typeof vType=='undefined')//	{vType="Child"}if(typeof vEditSubform=='undefined')	{vEditSubform="Body-NewDocument"}	if(typeof vBodyStyle=='undefined')	{vBodyStyle=""}	else	{vBodyStyle="&BodyStyle=" + vBodyStyle}var vAddressvar vDb=vDocument["Database"]f = document.forms[0];var vDocId = vDocument["DocumentId"]vAddress =  "/" + vDb + "/" + vForm + "?OpenForm&ParentUNID=" + vDocId + "&Subform=" + vEditSubform + vBodyStylevAddress +=  "&Type=" + vType	//ShowDialog(vAddress,"Application",500,500);	 //var vParameters ="width=500,height=400,left=80,top=80,scrollbars=no,resizable=yes"//window.open(vAddress,"Application",vParameters)window.location=vAddress}function processNew(vFamilyType,vBodyStyle,vSubformEdit,vBodyEdit,vNavigatorCategory){var vAddressvar vDb=vDocument["Database"]f = document.forms[0];var vDocId = vDocument["DocumentId"]//var vBody = escape(vDocument["Subform"])//var vType=""//var vCategory//var vSubject if(vFamilyType=='List'| vFamilyType=='Child')	{if(vDocument["ListCategory"]=='' | typeof vDocument["ListCategory"]=='undefined')		{		if(vDocument["Type"]==vDocument["Category"])			{vCategory = escape(vDocument["Subject"])}		else			{vCategory = escape(vDocument["Category"])}						     vSubject = escape(vDocument["Subject"])			}		else		{		var vUnderscore = inStr(vDocument["ListCategory"],'_')		var vLength = len(vDocument["ListCategory"])		vCategory =escape(vDocument["ListCategory"])		//vCategory =left(vDocument["ListCategory"],vUnderscore)		var vRight=vLength - vUnderscore-1		vSubject=right(vDocument["ListCategory"],vRight)    		}	}else if(vFamilyType=='Root')		{	if(vDocument["Type"]==vDocument["Category"])		{vCategory = escape(vDocument["Category"])		vFamilyType='Sibling'}	else		{vCategory = escape(vDocument["Category"])		}				vSubject = escape(vDocument["Subject"])	}else if(vFamilyType=='Navigator')		{		var vNavigatorParts = vNavigatorCategory.split('_');	vNavigatorParts[0];	vType="&Type=" +vNavigatorParts[0];	vCategory =vNavigatorParts[1];		for(var i=2;i < vNavigatorParts.length;i++) {		vCategory=+vNavigatorParts[i];	}		//vType="&Type=Page"//	vCategory = "Page"//		vCategory = escape(vCategoryOverride)	vSubformEdit="theContentTopicEdit"	}else	{		if(vDocument["Type"]==vDocument["Category"])		{vCategory = escape(vDocument["Subject"])}	else		{vCategory = escape(vDocument["Category"])}				vSubject = escape(vDocument["Subject"])		}var vLayout= escape(vDocument["Layout"])var vSuffixvAddress =  "/" + vDb + "/theLookupByDocumentId/" + vDocIdif (typeof vBodyEdit=='undefined')	{vBodyEdit=""}if (typeof vBodyStyle=='undefined')	{vBodyStyle=""}var vField=""if (vBodyEdit=="theListEdit" |vBodyEdit=="theLinkEdit")	vField="&Field=theList"else if (vBodyEdit=="thePrimaryEdit")	{	vField="&Field=thePrimary"	}else	{	vField="&Field=" + vBodyEdit}var vTabsif (vBodyStyle=="ListOnly" | vBodyStyle=="Link")	{vTabs="YNHHN"}//	else if (vField=="&Field=theSecondary")//	{vTabs="NNNYN"}	else	{vTabs="YNNHN"}	// http://localhost/theSourceTesting.nsf/theForm?OpenForm&ParentUNID=825E1A562AE2D6BD862573230056ABD9&Subject=Main&Category=&LayoutSubform=theFormBody&Subform=theHelpEdit&BodyStyle=RichText&BodyEdit=&Tabs=YNNHH	//alert(vFamilyType)	if (vBodyEdit=="RichText")	{ 	vType = "&Type=Help"	if (vFamilyType=='Response') 		{//vAddress='/'+ vDb + '/theFormHelpResponse?OpenForm&Subform=Body-NewRichText&Type=Help&BodyStyle=Help'		//vAddr/ess+=  "&ParentUNID=" + vDocId		vAddress= '/'+ vDb + '/theFormHelpResponse?OpenForm&ParentUNID=' + vDocId  + '&Subform=theNew' + vType + '&BodyEdit=theRichTextEdit'		}	else 		{		vAddress= '/'+ vDb + '/theFormHelp?OpenForm&ParentUNID=' + vDocId  + '&Subform=theNew' + vType + '&BodyEdit=theRichTextEdit'}	}else	{//	http://localhost/theSourceTesting.nsf/theForm?OpenForm&ParentUNID=40326EF56FEFDC488625745900411A59&Category=Concrete%20Stamping//&Layout=Default&Subform=theContentEditTab&BodyStyle=Link&BodyEdit=theLinkCommon&Tabs=YNHHH&End	vAddress =  "/" + vDb + "/theForm?OpenForm&ParentUNID=" + vDocId  + "&Subject=" + vSubject + "&Category=" + vCategory + "&Layout=" + vLayout //theNew   vAddress+= "&Subform=theNew" + "&BodyStyle=" + vBodyStyle + vField          vAddress+= "&Subform=" + vSubformEdit+ "&BodyStyle=" + vBodyStyle	vAddress +=  "&BodyEdit=" + vBodyEdit		//      vSuffix="?editDocument&Subform=" + vType + "Tab"    vAddress =  vAddress  + "&Tabs=" + vTabs//		vAddress =  "/" + vDb + "/theForm?OpenForm&ParentUNID=" + vDocId  + "&Subject=" + vSubject + "&Category=" + vCategory + "&Layout=" + vLayout //          vAddress+= "&Subform=" + vSubformEdit+ "&BodyStyle=" + vBodyStyle + vField + vType//	vAddress +=  "&BodyEdit=" + vBodyEdit  + vFamilyTypeParamater + "&theEnd"	}	window.location=vAddress	return	}function processNewXX(vFamilyType,vBodyEdit,vBodyStyle,vNavigatorCategory){//child,listedit,listonlyvar vSubformEdit="theContentEdit"//Child theListEdit BodyStandardvar vAddress//var vSubformvar vDb=vDocument["Database"]f = document.forms[0];var vDocId = vDocument["DocumentId"]var vBody = escape(vDocument["Subform"])var vType=""var vCategoryvar vSubject if(vFamilyType=='List'| vFamilyType=='Child')	{if(vDocument["ListCategory"]=='' | typeof vDocument["ListCategory"]=='undefined')		{		if(vDocument["Type"]==vDocument["Category"])			{vCategory = escape(vDocument["Subject"])}		else			{vCategory = escape(vDocument["Category"])}						     vSubject = escape(vDocument["Subject"])			}		else		{		var vUnderscore = inStr(vDocument["ListCategory"],'_')		var vLength = len(vDocument["ListCategory"])		vCategory =escape(vDocument["ListCategory"])		//vCategory =left(vDocument["ListCategory"],vUnderscore)		var vRight=vLength - vUnderscore-1		vSubject=right(vDocument["ListCategory"],vRight)    		}	}else if(vFamilyType=='Root')		{	if(vDocument["Type"]==vDocument["Category"])		{vCategory = escape(vDocument["Category"])		vFamilyType='Sibling'}	else		{vCategory = escape(vDocument["Category"])		}				vSubject = escape(vDocument["Subject"])	}else if(vFamilyType=='Navigator')		{		var vNavigatorParts = vNavigatorCategory.split('_');	vNavigatorParts[0];	vType="&Type=" +vNavigatorParts[0];	vCategory =vNavigatorParts[1];		for(var i=2;i < vNavigatorParts.length;i++) {		vCategory=+vNavigatorParts[i];	}		//vType="&Type=Page"//	vCategory = "Page"//		vCategory = escape(vCategoryOverride)	vSubformEdit="theContentTopicEdit"	}else	{		if(vDocument["Type"]==vDocument["Category"])		{vCategory = escape(vDocument["Subject"])}	else		{vCategory = escape(vDocument["Category"])}				vSubject = escape(vDocument["Subject"])		}var vLayout= escape(vDocument["Layout"])var vSuffixvAddress =  "/" + vDb + "/theLookupByDocumentId/" + vDocIdif (typeof vBodyEdit=='undefined')	{vBodyEdit=""}if (typeof vBodyStyle=='undefined')	{vBodyStyle=""}var vField=""if (vBodyEdit=="theListEdit" |vBodyEdit=="theLinkEdit")	vField="&Field=theList"else if (vBodyEdit=="thePrimaryEdit")	{	vField="&Field=thePrimary"	}else	{	vField="&Field=" + vBodyEdit}var vFamilyTypeParamater //alert(vBodyEdit)if (vFamilyType=='undefined')	{vFamilyTypeParamater =""}//else if (vBodyEdit=='LinkEdit')//	{vFamilyType="&FamilyType=LinkOnly"}	else if (vFamilyType=='Child')	{vFamilyTypeParamater ="&FamilyType=Child"}else if (vFamilyType=='List')	{vFamilyTypeParamater ="&FamilyType=Child"}else if (vFamilyType=='Sibling')	{vFamilyTypeParamater ="&FamilyType=Sibling"}	else if (vFamilyType=='Root')	{vFamilyTypeParamater ="&FamilyType=Root"}	else	{vFamilyTypeParamater =""}				if (vBodyEdit=="RichText")	{ 	vType = "&Type=Help"	if (vFamilyType=='Response') 		{//vAddress='/'+ vDb + '/theFormHelpResponse?OpenForm&Subform=Body-NewRichText&Type=Help&BodyStyle=Help'		//vAddr/ess+=  "&ParentUNID=" + vDocId		vAddress= '/'+ vDb + '/theFormHelpResponse?OpenForm&ParentUNID=' + vDocId  + '&Subform=theNew' + vType + '&BodyEdit=theRichTextEdit'		}	else 		{		vAddress= '/'+ vDb + '/theFormHelp?OpenForm&ParentUNID=' + vDocId  + '&Subform=theNew' + vType + '&BodyEdit=theRichTextEdit'}	}else	{//	http://localhost/theSourceTesting.nsf/theForm?OpenForm&ParentUNID=40326EF56FEFDC488625745900411A59&Category=Concrete%20Stamping//&Layout=Default&Subform=theContentEditTab&BodyStyle=Link&BodyEdit=theLinkCommon&Tabs=YNHHH&End	vAddress =  "/" + vDb + "/theForm?OpenForm&ParentUNID=" + vDocId  + "&Subject=" + vSubject + "&Category=" + vCategory + "&Layout=" + vLayout //theNew   vAddress+= "&Subform=theNew" + "&BodyStyle=" + vBodyStyle + vField          vAddress+= "&Subform=" + vSubformEdit+ "&BodyStyle=" + vBodyStyle + vField + vType	vAddress +=  "&BodyEdit=" + vBodyEdit//		vAddress =  "/" + vDb + "/theForm?OpenForm&ParentUNID=" + vDocId  + "&Subject=" + vSubject + "&Category=" + vCategory + "&Layout=" + vLayout //          vAddress+= "&Subform=" + vSubformEdit+ "&BodyStyle=" + vBodyStyle + vField + vType//	vAddress +=  "&BodyEdit=" + vBodyEdit  + vFamilyTypeParamater + "&theEnd"	}	window.location=vAddress	return	}function processBasic(vBodyEdit,vMainSubform){var vAddressvar vSubformvar vDb=vDocument["Database"]if (typeof vMainSubform=='undefined')	{vMainSubform="theBasic"}	if (typeof vBodyEdit=='undefined')	{vBodyEdit=""	}else if (vBodyEdit=='theSettingsLayout')	{vBodyEdit=""	vMainSubform="theSettingsLayout"	}else if (vBodyEdit=="theDocumentSettings")	{vBodyEdit=""	vMainSubform="theDocumentSettings"	}else	{vBodyEdit="&BodyEdit="+ vBodyEdit}//var f = document.forms[0];var vDocId = vDocument["DocumentId"]var vBody = vDocument["Subform"]var vSuffix	vAddress =  "/" + vDb + "/theLookupByDocumentId/" + vDocId + "?editDocument&Subform=" + vMainSubform + vBodyEditlocation.href= vAddress	}function processBasic(vBodyEdit,vMainSubform){var vAddressvar vSubformvar vDb=vDocument["Database"]if (typeof vMainSubform=='undefined')	{vMainSubform="theBasic"}	if (typeof vBodyEdit=='undefined')	{vBodyEdit=""	}else if (vBodyEdit=='theSettingsLayout')	{vBodyEdit=""	vMainSubform="theSettingsLayout"	}else if (vBodyEdit=="theDocumentSettings")	{vBodyEdit=""	vMainSubform="theDocumentSettings"	}else	{vBodyEdit="&BodyEdit="+ vBodyEdit}//var f = document.forms[0];var vDocId = vDocument["DocumentId"]var vBody = vDocument["Subform"]var vSuffix	vAddress =  "/" + vDb + "/theLookupByDocumentId/" + vDocId + "?editDocument&Subform=" + vMainSubform + vBodyEditlocation.href= vAddress	}function adjustRightObjectWidth(tableID, widthPct,adjustAmount) {  //  execute for Opera only  //if(parseInt(navigator.appVersion)< 5//    || !navigator.userAgent.indexOf(MSIE)) return;  if(widthPct == "" || widthPct == null) widthPct = 100;  var table = document.getElementById(tableID);  if(table == null) return; // no table, nothing to do!  var body_w = document.body.clientWidth;  table.style.width = (body_w -adjustAmount) * (widthPct / 100);  }/// This is the stuff originally in utilities.jsfunction none(){}var allPageTags = new Array(); function changeBorderByClass(theClass,vBorder){ //Populate the array with all the page tags  var allPageTags=document.getElementsByTagName("*");//Cycle through the tags using a for loop  for (i=0; i<allPageTags.length; i++) 	{  //Pick out the tags with our class name	  if (allPageTags[i].className==theClass) 		{  //Manipulate this in whatever way you want  		allPageTags[i].style.border=vBorder;  		break;		}	}} function changeWidthByClass(theClass,vWidth){//Populate the array with all the page tags  var allPageTags=document.getElementsByTagName("*");//Cycle through the tags using a for loop  for (i=0; i<allPageTags.length; i++) 	{  //Pick out the tags with our class name	  if (allPageTags[i].className==theClass) 		{  //Manipulate this in whatever way you want  		allPageTags[i].style.width=vWidth;  		break;		}	}} function getWidthByClass(theClass){//Populate the array with all the page tags  var allPageTags=document.getElementsByTagName("*");var vWidth=0;//alert(allPageTags.length)//Cycle through the tags using a for loop  for (i=0; i<allPageTags.length; i++) 	{  //Pick out the tags with our class name	  if (allPageTags[i].className==theClass) 		{  //Manipulate this in whatever way you want  		vWidth=allPageTags[i].style.width  		break;		}	}	return vWidth} function changeHeightByClass(theClass,vHeight){//Populate the array with all the page tags  var allPageTags=document.getElementsByTagName("*");//Cycle through the tags using a for loop  for (i=0; i<allPageTags.length; i++) 	{  //Pick out the tags with our class name	  if (allPageTags[i].className==theClass) 		{  //Manipulate this in whatever way you want  		allPageTags[i].style.height=vHeight;  		break;		}	}} function showSections() {//image=document.getElementById('logo');//if (image) //	{//	     eval("document.all.logo.style.border='4px dashed red'");		//changeBorderByClass("logo","2px dashed green")    //	}	var image;changeBorderByClass("summaryDiv","2px dashed yellow")//changeBorderByClass("listCurrentDiv","2px dashed black")changeBorderByClass("primarySection","2px dashed red")//image=document.getElementById('primarySection');//if (image) //	{//	changeBorderByClass("primarySection","2px dashed red")//	}//else//	{//	image=document.getElementById('primarySectionOverride');//	if (image) //	{//	changeBorderByClass("primarySection","2px dashed red")//	}//	}changeBorderByClass("secondarySection","2px dashed green")	//image=document.getElementById('secondarySection');//if (image) //	{//	changeBorderByClass("secondarySection","2px dashed green")    //	}//   eval("document.all.vertical.style.border='2px dashed red'");	image=document.getElementById('navSection');if (image) 	{     eval("document.all.navSection.style.border='2px dashed #FF80FF'");	     eval("document.all.navSection.title='Photo Nav Section'");		} changeBorderByClass("listSection","2px dashed blue") //image=document.getElementById('listContainer');//if (image) //	{//      eval("document.all.listContainer.style.border='2px dashed blue'");//	}	//image=document.getElementById('sectionMenu');//if (image) //	{ //      eval("document.all.menuPrimary.style.border='2px dashed red'");  //     eval("document.all.menuList.style.border='2px dashed blue'");//       eval("document.all.menuSecondary.style.border='2px dashed green'");	        //      eval("document.all.sectionMenu.style.display='block'");     //      eval("document.all.menuPrimarySummary.style.border='2px dashed yellow'");       //	}	  //    eval("document.all.secondarySection.style.border='2px dashed green'");//        changeBorderByClass("secondarySection","2px dashed green")       //      eval("document.getElementById('listCurrentId').style.border = '2px dashed black'"); //image=document.getElementById('listCurrentDiv');//if (image) //	{//      changeBorderByClass("listCurrentDiv","2px dashed black")//	}//       else//       {//       image=document.getElementById('listCurrentDivOverride');//	  if (image) //		{changeBorderByClass("listCurrentDiv","2px dashed yellow") } //     }	          //       eval("document.getElementById('highLite').style.border = '2px dashed yellow'");//changeBorderByClass("listSection","2px dashed yellow") //image=document.getElementById('summaryDiv');//if (image) //	{//       changeBorderByClass("summaryDiv","2px dashed yellow")//       }//       else//       {//       image=document.getElementById('summaryDivOverride');//	  if (image) //		{changeBorderByClass("summaryDiv","2px dashed yellow") }//       }}function showInfo() {var vNavInfo = "<br><br><br><div id=showInfo>"	for (var i in vDocument)	{if(left(i,1) !="_")		{vNavInfo += i+' : ' + vDocument[i] + "<br>"		}	}vNavInfo += "</div>"navBody.innerHTML=vNavInfo}function showUsers() {var vNavInfo = "<br><br><br><div id=showInfo>"	for (var i in vUsers)	{		vNavInfo += vUsers[i] + "<br>"	}vNavInfo += "</div>"navBody.innerHTML=vNavInfo}function showNavigators() {var image;changeBorderByClass("horizontalPrimary","2px dashed red")changeBorderByClass("verticalPrimary","2px dashed red")changeBorderByClass("verticalSecondary","2px dashed green")changeBorderByClass("verticalChildren","2px dashed yellow")changeBorderByClass("verticalSiblings","2px dashed black")changeBorderByClass("verticalHTML","2px dashed #FF80FF")changeBorderByClass("horizontalHTML","2px dashed #FF80FF")changeBorderByClass("verticalCustom","2px dashed #FF80FF")changeBorderByClass("resourceNavigator","2px dashed blue")var vNavInfo = "<table><tr><td valign=top><br><br>"vNavInfo +="<div class=showPrimary>Primary"vNavInfo += "<br>See Layout resource:" + vDocument["Layout"]vNavInfo += "</div>"vNavInfo += "<div class=showChildren>Children"image=document.getElementById('verticalTitleChildren');if (image) 	{	vNavInfo += "<br>Title: " + verticalTitleChildren.innerHTML 	}vNavInfo += "</div>"vNavInfo += "<div class=showSiblings>Siblings"image=document.getElementById('verticalTitleSibling');if (image) 	{	vNavInfo += "<br>Title: " + verticalTitleSibling.innerHTML 	}vNavInfo += "</div>"vNavInfo += "<div class=showSecondary>Secondary" image=document.getElementById('verticalTitleSecondary');if (image) 	{	vNavInfo += "<br>Title: " + verticalTitleSecondary.innerHTML 	}vNavInfo += "</div>"vNavInfo +="<div class=showResource>Resource Navigator"vNavInfo += "<br>See documentation"vNavInfo += "</div>"vNavInfo +="<div class=showOther>Other Navigators"vNavInfo += "<br>See documentationn"vNavInfo += "</div>"vNavInfo +="</td></tr></table>"navBody.innerHTML=vNavInfochangeBorderByClass("showPrimary","2px dashed red")changeBorderByClass("showPrimaryVertical","2px dashed red")changeBorderByClass("showChildren","2px dashed yellow")changeBorderByClass("showSiblings","2px dashed black")changeBorderByClass("showSecondary","2px dashed green")changeBorderByClass("showResource","2px dashed blue")//changeBorderByClass("showOther","2px dashed #FF80FF")       	}function left(str, n)        /***                IN: str - the string we are LEFTing                    n - the number of characters we want to return                RETVAL: n characters from the left side of the string        ***/        {                if (n <= 0)     // Invalid bound, return blank string                        return "";                else if (n > String(str).length)   // Invalid bound, return                        return str;                // entire string                else // Valid bound, return appropriate substring                        return String(str).substring(0,n);        }     	function right(str, n)        /***                IN: str - the string we are RIGHTing                    n - the number of characters we want to return                RETVAL: n characters from the right side of the string        ***/        {                if (n <= 0)     // Invalid bound, return blank string                   return "";                else if (n > String(str).length)   // Invalid bound, return                   return str;                     // entire string                else { // Valid bound, return appropriate substring                   var iLen = String(str).length;                   return String(str).substring(iLen, iLen - n);                }        }function len(str)        /***                IN: str - the string whose length we are interested in                RETVAL: The number of characters in the string        ***/        {  return String(str).length;  }function inStr(strSearch, charSearchFor)/*InStr(strSearch, charSearchFor) : Returns the first location a substring (SearchForStr)                           was found in the string str.  (If the character is not                           found, -1 is returned.)                      Requires use of:	Mid function	Len function*/{	for (i=0; i < len(strSearch); i++)	{	    if (charSearchFor == mid(strSearch, i, 1))	    {			return i;	    }	}	return -1;}function mid(str, start, theLen)        /***                IN: str - the string we are LEFTing                    start - our string's starting position (0 based!!)                    len - how many characters from start we want to get                RETVAL: The substring from start to start+len        ***/        {                // Make sure start and len are within proper bounds                if (start < 0 || theLen < 0) return "";                var iEnd, iLen = String(str).length;                if (start + theLen > iLen)                        iEnd = iLen;                else                        iEnd = start + theLen;                return String(str).substring(start,iEnd);        }  function rightBack(sourceStr, keyStr){arr = sourceStr.split(keyStr);return (sourceStr.indexOf(keyStr) == -1 | keyStr=='') ? '' : arr.pop()}function leftBack(sourceStr, keyStr){arr = sourceStr.split(keyStr)arr.pop();return (keyStr==null | keyStr=='') ? '' : arr.join(keyStr)}function trim(stringToTrim) {	return stringToTrim.replace(/^\s+|\s+$/g,"");}function ltrim(stringToTrim) {	return stringToTrim.replace(/^\s+/,"");}function rtrim(stringToTrim) {	return stringToTrim.replace(/\s+$/,"");}function replaceSubstring(inputString, fromString, toString) {   // Goes through the inputString and replaces every occurrence of fromString with toString   var temp = inputString;   if (fromString == "") {      return inputString;   }   if (toString.indexOf(fromString) == -1) { // If the string being replaced is not a part of the replacement string (normal situation)      while (temp.indexOf(fromString) != -1) {         var toTheLeft = temp.substring(0, temp.indexOf(fromString));         var toTheRight = temp.substring(temp.indexOf(fromString)+fromString.length, temp.length);         temp = toTheLeft + toString + toTheRight;      }   } else { // String being replaced is part of replacement string (like "+" being replaced with "++") - prevent an infinite loop      var midStrings = new Array("~", "`", "_", "_","#");      var midStringLen = 1;      var midString = "";      // Find a string that doesn't exist in the inputString to be used      // as an "inbetween" string      while (midString == "") {         for (var i=0; i < midStrings.length; i++) {            var tempMidString = "";            for (var j=0; j < midStringLen; j++) { tempMidString += midStrings[i]; }            if (fromString.indexOf(tempMidString) == -1) {               midString = tempMidString;               i = midStrings.length + 1;            }         }      } // Keep on going until we build an "inbetween" string that doesn't exist      // Now go through and do two replaces - first, replace the "fromString" with the "inbetween" string      while (temp.indexOf(fromString) != -1) {         var toTheLeft = temp.substring(0, temp.indexOf(fromString));         var toTheRight = temp.substring(temp.indexOf(fromString)+fromString.length, temp.length);         temp = toTheLeft + midString + toTheRight;      }      // Next, replace the "inbetween" string with the "toString"      while (temp.indexOf(midString) != -1) {         var toTheLeft = temp.substring(0, temp.indexOf(midString));         var toTheRight = temp.substring(temp.indexOf(midString)+midString.length, temp.length);         temp = toTheLeft + toString + toTheRight;      }   } // Ends the check to see if the string being replaced is part of the replacement string or not   return temp; // Send the updated string back to the user} // Ends the "replaceSubstring" functionfunction returnProcessing(vReturnField){// dummy function for returning from Name Pick function}function getValue(f,vFieldName)	{	var vValue=''	if(typeof f[vFieldName]=='undefined')		{		vValue=''		return vValue				}	var vFieldLength=f[vFieldName].length;	if(typeof vFieldLength!='number')		{		if(f[vFieldName].checked==true)			{// Removed + ";" from end of next line - Doug	//		vValue=f[vFieldName].value			vValue=f[vFieldName][i].text + ";"			}		else			{vValue=""}		return vValue		};	if(f[vFieldName].type=='select-one')		{for (var i=0; i<vFieldLength; i++)			{if (f[vFieldName][i].selected)				{vValue=f[vFieldName][i].text + ";"}			}		}		else	if(f[vFieldName].type=='select-multiple')		{vValue=''		for (var i=0; i<vFieldLength; i++)			{if (f[vFieldName][i].selected)				{vValue+=vValue=f[vFieldName][i].text + ";"}			}		}		else			{			for (var i=0; i<vFieldLength; i++)			//alert(.theGraphicDialogFlag[0].checked)				if(f[vFieldName][i].checked==true)					{					vValue+=f[vFieldName][i].value + ";"					}			}if(len(vValue)>0)	{return left(vValue,(len(vValue)-1))}else	{return vValue}	}	function checkPermission(vRole){//f = document.forms[0];if (vDocument["Server"]=='localhostX' | vDocument["Database"]=='site/LibrarianDemo.nsf')	{return true}//if (f.daServerName.value=='localhost' | f.daServerName.value=='demo.sitelibrarian.com')vDocument["SiteAdmin"]="No"var vPass=falsefor ( rown = 0; rown < vUsers.length; rown++) 	{	if(vUsers[rown]==vRole)		{		return true;		}	if(vUsers[rown]=="Change this to admin group*")		{vDocument["SiteAdmin"]="Yes"		}		}	{return -1}}function writeActions(vLocation){	 var tablehtml="" if(vLocation=="Horizontal")   {    tablehtml += "<table width=100% align=center><tr><td align=center>"    }tablehtml += "<div id=actionNav align=center>"if(vDocument["Browser"]!="Microsoft"){tablehtml+="<div id=" + vDirection + ">Edit actions are supported in Microsoft browsers only</div>"}else{for ( rown = 0; rown < vView.length; rown++){if(vView[rown].EditMode==vDocument["EditMode"] | vView[rown].EditMode=="Both")     {	tablehtml +="<div id=actionPadding>";                var vDirection	var vSeperator	if(vLocation=="Horizontal")  	 {	   vDirection ="actionInnerHor";	   vSeperator="|";  	 }	else  	 {	   vDirection="actionInnerVer";	   vSeperator="-";  	 }	tablehtml +="<div id=" + vDirection + ">" + vView[rown].ProductHTML + "</div>"	tablehtml +="<div id=" + vDirection + ">" + vSeperator + "</div>"	tablehtml +="</div>";      }	}}tablehtml +="</div>";if(vLocation=="Horizontal")   {    tablehtml +="</td></tr></table>";   }		document.write(tablehtml)}function theDocument(theID,	theSubject,	theDescription,	theBodyStyle,	theList,	theAddress,	theGraphic,	theHTML_1,	theHTML_2,		theBCflag,		theOrder	){	this.ID=theID;	this.Subject=theSubject;	this.Description=theDescription;	this.BodyStyle=theBodyStyle;	this.List=theList;	this.Address=theAddress;	this.Graphic=theGraphic;	this.HTML_1=theHTML_1;		this.HTML_2=theHTML_2;		this.BCflag=theBCflag;			this.Order=theOrder;}function theDocList(){var Listthis.List = []this.addToList=addToList;//this.vObject=vObject;}function addToList(theID,	theSubject,	theDescription,	theBodyStyle,	theList,	theAddress,	theGraphic,	theHTML_1,	theHTML_2,		theBCflag,	theOrder){this.List[this.List.length]=new theDocument(theID,theSubject,theDescription,theBodyStyle,theList,theAddress,theGraphic,theHTML_1,	theHTML_2,theBCflag,theOrder)}function runDisplay(vListName,vPageSetting,vListArray,vColumn){var f=document.forms[0];	if(vListArray.List.length>0){	var vListStyle=getListStyle(vPageSetting)	if (vListStyle=="Table" | vListStyle=="")		{displayList(vListName,vPageSetting,vListArray,vColumn);		}	else		{displayDiv(vPageSetting,vListArray,vColumn);		}	}}	function displayList(vListName,vPageSetting,vArray,vColumn, vDb){var vEditor=checkPermission( '[Librarian]' );var f=document.forms[0];var vOverrideSectionIdvar vOverrideTitleIdvar vOverrideBodyIdif(vPageSetting=="Override Definition")	{vOverrideSectionId=" id=listSectionOverride"	vOverrideTitleId=" id=listTitleOverride"	vOverrideBodyId=" id=listBodyOverride"	}else	{	vOverrideSectionId=""	vOverrideTitleId=""	vOverrideBodyId=""	}		var vCategoryvar vSubjectvCategory=vDocument["Category"]vSubject=vDocument["Subject"]vCategory= replaceSubstring(vDocument["Category"],' ','+')//alert(vCategory)vCategory =replaceSubstring(vCategory,'&','andand')  vSubject=replaceSubstring(vDocument["Subject"],' ','+')vSubject =replaceSubstring(vSubject,'&','andand') var vParameter=""var vMoreInfoLinkvar vMoreInfo = 'More Info...'var vEditLink=''//var vArray//vArray=vListArrayvar vAdjust=0;var vLinkvar vGraphicvar vListvar tablehtml = "<div class=" + vListName + "Container>"tablehtml += "<table  width=100% cellspacing=10px cellpadding=0 class=tableContainer>"var vAnchorvar vline="<IMG height=10 alt=----- src='images/line.gif' width=80%>"var vlistTitleif(typeof vDb=="undefined")	{vDb=vDocument["Database"]}if(typeof vColumn=="undefined")	{vColumn=2}var vWidthif(vColumn==0)	{return true}else if(vColumn==1)	{vWidth='100%'	vSwitchNumber=1}else if(vColumn==3)	{vWidth='33%'	vSwitchNumber=2}else	{vWidth='50%'	vSwitchNumber=1	vColumn=2}//var vTitleClassfor ( rown = 0; rown < vArray.List.length; rown++) {        vList=unescape(vArray.List[rown].List) //alert(vArray.List[rown].BCflag)  if (vArray.List[rown].BCflag=='N')	{vParameter=""}else	{//	alert(f.daLinkOrigin.value)	if (vDocument["LinkOrigin"]=="")		{		if(vCategory=='' | typeof vCategory=='undefined')			{			vParameter=''			}		else		{				vParameter = '&BCdb=' + vDocument["Database"] + '&BCtype=' + vDocument["Type"] +  '&BCcategory=' 		if(vCategory==vDocument["Type"])			{vParameter +=vSubject			}		else			{vParameter +=vCategory + '_' +vSubject			}		}	}	else		{vParameter = vDocument["LinkOrigin"]}	}		if(vListName=="Comment")	{	vMoreInfoLink=""	}else		{	vMoreInfoLink= "<div class=" + vListName + "MoreInfoLink><a href=" + unescape(vArray.List[rown].Address + vParameter) +">" + vMoreInfo + "</a></DIV>"	}						//alert(unescape(vArray.List[rown].List) )       vAnchor="<IMG height=10 alt=----- src='images/line.gif' width=80% id=" + vArray.List[rown].Subject +"></a><br><br>"         if((rown + vAdjust) % vColumn==0)		{tablehtml +="<tr>";		}		if(vArray.List[rown].BodyStyle=="ListOnly")			{		//	vLink=vArray.List[rown].theLink		//	vGraphic=vArray.List[rown].theGraphic		//	vLink= "<div id=listLink><a href=" + vArray.List[rown].Address +">" + vArray.List[rown].Description + "</a></DIV>"		//	vGraphic= "<div id=listLink><a href=" + vArray.List[rown].Address +">" + vArray.List[rown].Graphic + "</a></DIV>"			vLink= "<a name='#" + replaceSubstring(vArray.List[rown].Subject," ","")  + "'></a>" + vArray.List[rown].Description			vGraphic= vArray.List[rown].Graphic			vlistTitle='listOnlyTitle'			if (vEditor==true)				vEditLink="<br><center><a href=/" + vDb + "/0/" + vArray.List[rown].ID + "?opendocument>edit List Only</a></center>"			else				{vEditLink=""}							}		else if(vArray.List[rown].BodyStyle=="Link")			{//alert('Subject' + vArray.List[rown].Subject)//alert('Description' + vArray.List[rown].Description)//alert('List' + vArray.List[rown].List)//alert('Address' + vArray.List[rown].Address)//alert('Graphic' + vArray.List[rown].Graphic)//alert('BodyStyle' + vArray.List[rown].BodyStyle)	if(vListName=="Comment")		{			vLink= "<div class=" + vListName + "TitleLink>" + vArray.List[rown].Description + "</DIV>"					vGraphic= "<div class=" + vListName + "TitleLink>" + vArray.List[rown].Graphic + "</DIV>"			}	else			{			vLink= "<div class=" + vListName + "TitleLink><a href=" + vArray.List[rown].Address + vParameter +">" + vArray.List[rown].Description + "</a></DIV>"			vGraphic= "<div class=" + vListName + "TitleLink><a href=" + vArray.List[rown].Address + vParameter   +">" + vArray.List[rown].Graphic + "</a></DIV>"		}			//	vGraphic=vArray.List[rown].Graphic			vlistTitle='listTitle'			if (vEditor==true)				vEditLink="<br><center><a href=/" + vDb + "/0/" + vArray.List[rown].ID + "?opendocument>edit Link</a></center>"			else				{vEditLink=""}				}		else if(vArray.List[rown].BodyStyle=="ListHeader")			{						vLink=vArray.List[rown].Description			vGraphic=vArray.List[rown].Graphic	//		vLink= "<div id=listLink><a href=" + vArray.List[rown].Address +">" + vArray.List[rown].Description + "</a></DIV>"	//		vGraphic= "<div id=listLink><a href=" + vArray.List[rown].Address +">" + vArray.List[rown].Graphic + "</a></DIV>"			vlistTitle='listTitle'				if (vEditor==true)				{vEditLink="<div align=center class='listHeaderBody'><a href=/" + vDb + "/0/" + vArray.List[rown].ID + "?opendocument>edit List Header</a></div>"}			else				{vEditLink=""}				}		else			{		//	vLink="<div id=listLink><a href=/" + vDb + "/0/" + vArray.List[rown].ID + "?opendocument" +  f.daLinkOrigin.value + ">" + vArray.List[rown].Description+ "</a></div>";			vGraphic="<a href=" + vArray.List[rown].Address +  vParameter + ">" + vArray.List[rown].Graphic+ "</a>";						//vLink= "<div id=" + vListName + "TitleLink><a href=" + vArray.List[rown].Address +  vParameter + ">" + vArray.List[rown].Description + "</a></DIV>"			if(vListName=='Comment')				{vLink=vArray.List[rown].Description				}			else				{vLink= "<div class=" + vListName + "TitleLink><a href=" + vArray.List[rown].Address +  vParameter + ">" + vArray.List[rown].Description + "</a></DIV>"				}		//	vGraphic= "<div id=listLink><a href=" + vArray.List[rown].Address +">" + vArray.List[rown].Graphic + "</a></DIV>"			vlistTitle='listTitle'				vEditLink=""					}//vLink= "<div id=listLink><a href=" + vArray.List[rown].Address +">" + vArray.List[rown].Description + "</a></DIV>"//vGraphic= "<div id=listLink><a href=" + vArray.List[rown].Address +">" + vArray.List[rown].Graphic + "</a></DIV>"	var vBody	     if(vArray.List[rown].BodyStyle=="ListHeader")              {              	vBody+='<div class=listInner>'              				    		vBody=unescape(vArray.List[rown].HTML_1)              			vBody+='<div' + vOverrideBodyId + ' class="listHeader">'			vBody+=unescape(vGraphic)			vBody+=unescape(vArray.List[rown].List) 			vBody+=vEditLink 			vBody+='</div>'	         //	    		vBody=unescape(vArray.List[rown].HTML_1)              //			vBody+='<table width=100% class="listHeaderTable" cellspacing="0"' + vOverrideSectionId + '><tbody>'//			vBody+='<tr><td' + vOverrideBodyId + ' class="listBody">' + unescape(vGraphic) + '</td></tr>'//			vBody+='<tr><td' + vOverrideBodyId + ' class="listBody"><p>' + unescape(vArray.List[rown].List) +   vEditLink +  '</p></td></tr>'//			vBody+='</tbody></table>'	               		if((rown + vAdjust) % vColumn==0)				{				tablehtml +="<td></td>";				tablehtml +="<tr><td colspan=" + vColumn + " align=center valign=top class=listTd>" + vBody + "</td></tr>"				vAdjust=vAdjust+vColumn-1;				}				else				{				tablehtml +="<tr><td colspan=" + vColumn + " align=center valign=top class=listTd>" + vBody + "</td></tr>"		 		vAdjust=0												}      		}		    else	    		{			vBody+='<div class=listInner>'	    		vBody=unescape(vArray.List[rown].HTML_1)//			vBody+='<table' + vOverrideSectionId + ' class="listTable" cellspacing="0" width=100%><tbody>'			vBody+='<div' + vOverrideTitleId + ' class="' + vlistTitle + '">' + unescape(vLink)  + '</div>'			vBody+='<div' + vOverrideBodyId + ' class="listBody">' +unescape(vGraphic) 			vBody+= vList 				    			 if(vArray.List[rown].BodyStyle!="ListOnly")				{				vBody+=vMoreInfoLink				}							vBody+=   vEditLink			vBody+='</div></div>'	    					tablehtml +="<td class=listTd width=" + vWidth + " valign=top>" + vBody + "</td>"			}//	    		{//	    		vBody=unescape(vArray.List[rown].HTML_1)//			vBody+='<table' + vOverrideSectionId + ' class="listTable" cellspacing="0" width=100%><tbody>'//			vBody+='<tr><th' + vOverrideTitleId + ' class="' + vlistTitle + '">' + unescape(vLink)  + '</th></tr>'//			vBody+='<tr><td' + vOverrideBodyId + ' class="listBody">' +unescape(vGraphic) + '</td></tr>'//			vBody+='<tr><td' + vOverrideBodyId + ' class="listBody"><p>' + vList + '</p></td></tr>'				    //			 if(vArray.List[rown].BodyStyle!="ListOnly")//				{//				vBody+='<tr><td' + vOverrideBodyId + ' class="listBody">' +unescape(vMoreInfoLink) + '</td></tr>'//				}				//			vBody+='<tr><td' + vOverrideBodyId + ' class="listBody"><p>' +   vEditLink + '</p></td></tr>'//			vBody+='</tbody></table>'	    		//			tablehtml +="<td width=" + vWidth + " valign=top>" + vBody + "</td>"//			}         if(((rown + vAdjust)% vColumn==vSwitchNumber) | vSwitchNumber==1)		{tablehtml +="</tr>";				}				}         if (((rown + vAdjust)% vColumn==vSwitchNumber) | vSwitchNumber==1)		{tablehtml +="<td>&nbsp;</td></tr>"		}tablehtml += "</table>"tablehtml += "</div>"document.write(tablehtml)//document.write("")}function displayDiv(vPageSetting,vArray,vColumn, vDb){var vEditor=checkPermission( '[Librarian]' );var f=document.forms[0];var vOverrideSectionIdvar vOverrideTitleIdvar vOverrideBodyIdif(vPageSetting=="Override Definition")	{vOverrideSectionId=" id=ListSectionOverride"	vOverrideTitleId=" id=ListTitleOverride"	vOverrideBodyId=" id=ListBodyOverride"	}else	{	vOverrideSectionId=""	vOverrideTitleId=""	vOverrideBodyId=""	}		var vCategoryvar vSubjectvar vParameter=""var vEditLink=''//var vArray//vArray=vListArrayvar vAdjust=0;var vLinkvar vGraphicvar vList//var tablehtml = "<table width=90% cellspacing=10px>"var tablehtml = "<table align=center width=100%><tr><td>"var vAnchorvar vline="<IMG height=10 alt=----- src='images/line.gif' width=80%>"var vlistTitleif(typeof vDb=="undefined")	{vDb=vDocument["Database"]}if(typeof vColumn=="undefined")	{vColumn=2}var vWidthif(vColumn==0)	{return true}else if(vColumn==1)	{vWidth='100%'	vSwitchNumber=1}else if(vColumn==3)	{vWidth='33%'	vSwitchNumber=2}else	{vWidth='50%'	vSwitchNumber=1	vColumn=2}for ( rown = 0; rown < vArray.List.length; rown++) {        vList=vArray.List[rown].List        vAnchor="<IMG height=10 alt=----- src='images/line.gif' width=80% id=" + vArray.List[rown].Subject +"></a><br><br>"         if((rown + vAdjust) % vColumn==0)		{//tablehtml +="<tr>";		}		if(vArray.List[rown].BodyStyle=="ListOnly")			{		//	vLink=vArray.List[rown].theLink		//	vGraphic=vArray.List[rown].theGraphic		//	vLink= "<div id=listLink><a href=" + vArray.List[rown].Address +">" + vArray.List[rown].Description + "</a></DIV>"		//	vGraphic= "<div id=listLink><a href=" + vArray.List[rown].Address +">" + vArray.List[rown].Graphic + "</a></DIV>"			vLink= vArray.List[rown].Description			vGraphic= vArray.List[rown].Graphic			vlistTitle='listOnlyHead'			if (vEditor==true)				vEditLink="<br><center><a href=/" + vDb + "/0/" + vArray.List[rown].ID + "?opendocument>edit List Only</a></center>"			else				{vEditLink=""}							}		else if(vArray.List[rown].BodyStyle=="Body-Link")			{//alert('Subject' + vArray.List[rown].Subject)//alert('Description' + vArray.List[rown].Description)//alert('List' + vArray.List[rown].List)//alert('Address' + vArray.List[rown].Address)//alert('Graphic' + vArray.List[rown].Graphic)//alert('BodyStyle' + vArray.List[rown].BodyStyle)vCategory= replaceSubstring(vDocument["Category"],' ','+')//alert(vCategory)vCategory =replaceSubstring(vDocument["Category"],'&','andand')  vSubject=replaceSubstring(vDocument["Subject"],' ','+')vSubject =replaceSubstring(vSubject,'&','andand') if (vArray.List[rown].BCflag=='N')	{vParameter=""}else	{//	alert(typeof daLinkOrigin.value)	if (vDocument["LinkOrigin"]=="")			if(vCategory=='' | typeof vCategory=='undefined')			{			vParameter=''			}		else			{				vParameter = '&BCdb=' + vDocument["Database"] + '&BCtype=' + vDocument["Type"] +  '&BCcategory=' +vCategory + '_' +vSubject			}	else		{vParameter = vDocument["LinkOrigin"]}	}			vLink= "<div id=listLink><a href=" + vArray.List[rown].Address + vParameter +">" + vArray.List[rown].Description + "</a></DIV>"			vGraphic= "<div id=listLink><a href=" + vArray.List[rown].Address + vParameter   +">" + vArray.List[rown].Graphic + "</a></DIV>"		//	vGraphic=vArray.List[rown].Graphic			vlistTitle='listTitle'			if (vEditor==true)				vEditLink="<br><center><a href=/" + vDb + "/0/" + vArray.List[rown].ID + "?opendocument>edit Link</a></center>"			else				{vEditLink=""}				}		else if(vArray.List[rown].BodyStyle=="ListHeader")			{						vLink=vArray.List[rown].Description			vGraphic=vArray.List[rown].Graphic	//		vLink= "<div id=listLink><a href=" + vArray.List[rown].Address +">" + vArray.List[rown].Description + "</a></DIV>"	//		vGraphic= "<div id=listLink><a href=" + vArray.List[rown].Address +">" + vArray.List[rown].Graphic + "</a></DIV>"			vlistTitle='listTitle'				if (vEditor==true)				{vEditLink="<br><center><a href=/" + vDb + "/0/" + vArray.List[rown].ID + "?opendocument>edit List Header</a></center>"}			else				{vEditLink=""}				}		else			{		//	vLink="<div id=listLink><a href=/" + vDb + "/0/" + vArray.List[rown].ID + "?opendocument" +  f.daLinkOrigin.value + ">" + vArray.List[rown].Description+ "</a></div>";			vGraphic="<a href=/" + vDb + "/0/" + vArray.List[rown].ID + "?opendocument" + vParameter + ">" + vArray.List[rown].Graphic+ "</a>";			vLink= "<div id=listLink><a href=" + vArray.List[rown].Address +  vParameter + ">" + vArray.List[rown].Description + "</a></DIV>"		//	vGraphic= "<div id=listLink><a href=" + vArray.List[rown].Address +">" + vArray.List[rown].Graphic + "</a></DIV>"			vlistTitle='listTitle'				vEditLink=""					}//vLink= "<div id=listLink><a href=" + vArray.List[rown].Address +">" + vArray.List[rown].Description + "</a></DIV>"//vGraphic= "<div id=listLink><a href=" + vArray.List[rown].Address +">" + vArray.List[rown].Graphic + "</a></DIV>"	var vBody	     if(vArray.List[rown].BodyStyle=="ListHeader")              {	    		vBody=unescape(vArray.List[rown].HTML_1)              			//vBody+='<table width=100% cellspacing="0"' + vOverrideSectionId + '><tbody>'			vBody+='<div' + vOverrideBodyId + ' class="listBody">' + unescape(vGraphic) + '<div>'			vBody+='<div' + vOverrideBodyId + ' class="listBody"><p>' + unescape(vArray.List[rown].List) +   vEditLink +  '</p></div>'			//vBody+='</tbody></table>'	                       		if((rown + vAdjust) % vColumn==0)				{				tablehtml +="<td></td>";				tablehtml +="<tr><td colspan=" + vColumn + " align=center valign=top>" + vBody + "</td></tr>"				vAdjust=vAdjust+1;				}				else				{				tablehtml +="<tr><td colspan=" + vColumn + " align=center valign=top>" + vBody + "</td></tr>"		 		vAdjust=0												}      		}		    else	    		{	    		vBody=unescape(vArray.List[rown].HTML_1)			//vBody+='<table' + vOverrideSectionId + ' class="listTable" cellspacing="0" width=100%><tbody>'			vBody+='<div class=listTable><div' + vOverrideTitleId + ' class="' + vlistTitle + '"><div style="padding-left:10px;padding-right:10px">' + unescape(vLink)  + '</div></div>'			vBody+='<div' + vOverrideBodyId + ' class="listBody">' +unescape(vGraphic) + '</div>'			vBody+='<div' + vOverrideBodyId + ' class="listBody"><p>' + unescape(vArray.List[rown].List)+   vEditLink + '</p></div>'			//vBody+='</tbody></table>'	    			vBody+='</div>'				//tablehtml +="<td width=" + vWidth + " valign=top>" + vBody + "</td>"			tablehtml+=vBody			}         if((rown + vAdjust)% vColumn==vSwitchNumber)		{//tablehtml +="</tr>";				}				}         if((rown + vAdjust) % vColumn <= vSwitchNumber)		{//tablehtml +="<td>&nbsp;</td></tr>"		}//tablehtml += "</table>"tablehtml += "</div></td></tr></table>"//tablehtml+= "</div>"document.write(tablehtml)}function navigatorHeading(vHeading){if(vDocument["Type"]==vDocument["Category"]){	if (vHeading=="theCategory")	{vDocument["Type"]}	else	{	vHeading="<a href=\\" + vDocument["Database"] + "/get" + vDocument["Type"]  + "/" + vDocument["Category"] +"_" + escape(vDocument["Subject"]) + ">" 	}}	var vHTML=""//document.write("<center><b>" + document.forms[0].daSubject.value + "</b></center>")if (vHeading=="theSubject")	{vHeading= vDocument["Subject"]}else if (vHeading=="theCategory")	{vHeading= vDocument["Category"]}	vHTML="<TABLE class=alerts cellSpacing=0 cellpadding=0 width=100%>"vHTML+="<TR><TD class=alertsHead><center><b>" + vHeading + "</b></center></TD></TR>"vHTML+="</TABLE>"document.write("<div id=verticalHeadingSec align=center>" + vHeading+ "</div>")}function displayPrimaryXX(){var vLinksvLinks='<a href=\\' + vDocument["Database"] + '>Home</a>'vLinks+=" | "vLinks+='<a href=\\' + vDocument["Database"] + '/theHelp?openframeset target=Help>Help</a>'document.write(vLinks)}function displayNavList(vResourceNavigator,vHeading,vArray,vColumn, vDb,vDirection,vType){//document.write("")	var vAdjust=0;var vLinkvar vGraphicLinkvar vListvar vWidthvWidth=''var vClassDiv=vResourceNavigator+"NavDiv"var vClassTitle=vResourceNavigator+"NavTitle"var vClassBody=vResourceNavigator+"NavBody"var vTRbeginvar vTRendvar vTableWidthvar tablehtml = "<div class=resourceNavigator>"if(vHeading!="")	{	tablehtml += '<div align=center id=' + vClassDiv + '>'	tablehtml += '<div align=center id=' + vClassTitle + '>' + vHeading + '</div>'	}if(typeof vDb=="undefined")	{vDb=vDocument["Database"]}	var vLinkSubjectfor ( rown = 0; rown < vArray.List.length; rown++) {        vList=vArray.List[rown].List 			if(vType=='icon')				{				if(vArray.List[rown].Graphic=='')					{					vLinkSubject=vArray.List[rown].Subject;										}					else					{					vLinkSubject=unescape(vArray.List[rown].Graphic);					}				}			else				{								vLinkSubject=vArray.List[rown].Subject;				}			vLink="<div id="  + vClassBody+ " align=center><a href=" + unescape(vArray.List[rown].Address) + ">" + vLinkSubject+ "</a></div>";						tablehtml += vLink }tablehtml += '</div>'tablehtml += '</div>'document.write(tablehtml)	}function getResourceNavigator(vResourceNavigator,vTitle,vDirection,vType){var vFunction ='Create' + vResourceNavigator + 'Array()'if (typeof vTitle=="undefined")	{vTitle=vResourceNavigator}if (typeof vDirection=="undefined")	{vDirection='vertical'}if (typeof vType=="undefined")	{vType='text'}var vCategoryArray= eval(vFunction);displayNavList(vResourceNavigator,vTitle,vCategoryArray,1,'',vDirection,vType);}function displayToolbar(vResourceNavigator,vArray,vDirection){var vLink=""var vLinkSubjectfor ( rown = 0; rown < vArray.List.length; rown++) {vLinkSubject=vArray.List[rown].Subject;switch(vArray.List[rown].Mode){case "Edit":  if(vDocument["EditMode"]=="Edit")  	{	vLink+="<a href=" + unescape(vArray.List[rown].Command) + ">" + vLinkSubject+ "</a>"	if (vDirection=="vertical")		{vLink+="<br><br><br>"}  	}  break    case "Read":  if(vDocument["EditMode"]=="Read")  	{	vLink+="<a href=" + unescape(vArray.List[rown].Command) + ">" + vLinkSubject+ "</a>"	if (vDirection=="vertical")		{vLink+="<br><br><br>"}  	}  breakdefault:	vLink+="<a href=" + unescape(vArray.List[rown].Command) + ">" + vLinkSubject+ "</a>"	if (vDirection=="vertical")		{vLink+="<br><br><br>"}}	}document.write(vLink)	}function getToolbar(vResourceNavigator,vDirection){var vFunction ='Create' + vResourceNavigator + 'Array()'if (typeof vDirection=="undefined")	{vDirection='horizontal'}var vCategoryArray= eval(vFunction);displayToolbar(vResourceNavigator,vCategoryArray,vDirection);}function addGraphicCurrent(){var f=document.forms[0]var vServerName=vDocument["Server"]var vLocalDirectory=vDocument["LocalDirectory"]var vDb=vDocument["Database"]var vLocalSubdirectoryvar vType=vDocument["Type"]var vCategory=vDocument["Category"]var vSubject=vDocument["Subject"]var vAddressvAddress="/" + vDb + "/" + "/theAttachmentAdd?openform&Type=" + vType + "&Category=" + vCategory + "_" + vSubjectShowDialog(vAddress,"Graphics",550,500)	}function deleteGraphicCurrent(){f = document.forms[0];var vDocId = vDocument["DocumentId"]var vDb=vDocument["Database"]var vAddress='/' + vDb + '/0/' + vDocId + '?editdocument&Subform=theAttachmentSubform&Function=Delete'location.href= vAddress	}function loadTools(vActionTools){var vAdminUser =vDocument["SiteAdmin"]// Navigationif(checkPermission("[AdvancedSL]")==true)	{	vActionTools.addToAction("","Navigation","Navigation Maintenance","Javascript:none()","Read","Main");	vActionTools.addToAction("","Primary","View parameters and layout navigation","Javascript:processEdit('Primary Navigator')","Read","Response");	vActionTools.addToAction("","Secondary","View parameters and layout navigation","Javascript:processEdit('Secondary Navigator')","Read","Response");	vActionTools.addToAction("","List/Child","View Current List Information","Javascript:none()","Read","SubMain");	vActionTools.addToAction("","Maintain","View Current List Information","Javascript:viewCategory('Children')","Read","SubResponse");	if(vDocument["HideChildNav"]=="Yes")		{vActionTools.addToAction("","Show Child Nav","Hide Child Navigator","Javascript:updateObject('theChildNavHide;No')","Read","SubResponse");}	else		{vActionTools.addToAction("","Hide Child Nav","Hide Child Navigator","Javascript:updateObject('theChildNavHide;Yes')","Read","SubResponse");}	vActionTools.addToAction("","Sibling","Sibling Navigator","Javascript:none()","Read","SubMain");	vActionTools.addToAction("","Maintain","Maintain Sibling Navigator","Javascript:viewCategory('Siblings')","Read","SubResponse");	if(vDocument["HideSiblingNav"]=="Yes")		{vActionTools.addToAction("","Show Sibling Nav","Hide Sibling Navigator","Javascript:updateObject('theSiblingNavHide;No')","Read","SubResponse");}	else		{vActionTools.addToAction("","Hide Sibling Nav","Hide Sibling Navigator","Javascript:updateObject('theSiblingNavHide;Yes')","Read","SubResponse");}	}	if (vAdminUser=="Yes"){	// Advanced	vActionTools.addToAction("","Advanced","Available document functions.","Javascript:none()","Read","Main");	//&Subform=theBasic&BodyEdit=DocumentSettings	vActionTools.addToAction("","Document Settings","Edit Current Document Settings","Javascript:processBasic('DocumentSettings')","Read","Response");	//vActionTools.addToAction("","Body Settings","Custom style settings","Javascript:processEdit('Body')","Read","Response");	//vActionTools.addToAction("","Settings","Edit List Settings","Javascript:processEdit('theSettingsList')","Read","Response");	//vActionTools.addToAction("","Settings","Edit Current List Settings","Javascript:processBasic('theSettingsListAll')","Read","Response");	//vActionTools.addToAction("","Layout","Edit Current List Settings","Javascript:processDocument('4')","Read","Response");	vActionTools.addToAction("","Layout Settings","Edit site layout settings","Javascript:processEdit('Layout')","Read","Response");	vActionTools.addToAction("","View Parent","Parent List","Javascript:viewListTools('Parent')","Read","Response");	vActionTools.addToAction("","View Root","List of base documents","Javascript:processList('Root')","Read","Response");	vActionTools.addToAction("","View All Current","View All Documents","Javascript:processList('Current')","Read","Response");	vActionTools.addToAction("","View All Documents","View All Documents","Javascript:processList('All')","Read","Response");	//vActionTools.addToAction("","List Settings","Edit List Settings","Javascript:processEdit('theSettingsList')","Read","Response"); 	vActionTools.addToAction("","Prototype","","Javascript:none()","Read","SubMain");	vActionTools.addToAction("","New Child","Edit List Settings","Javascript:createNew('Child','Prototype','thePrimary','PrototypeEdit')","Read","SubResponse");	vActionTools.addToAction("","New Sibling","Edit List Settings","Javascript:createNew('Sibling','Prototype','thePrimary','PrototypeEdit')","Read","SubResponse");	vActionTools.addToAction("","EditCurrent","Edit List Settings","Javascript:editDocument('theContentEdit','thePrimary')","Read","Response");}//vType,vRelationship,vBodyStyle,vField,vSubformEdit)//vActionTools.addToAction("","Site","Edit site layout settings","Javascript:processEdit('Layout')","Read","Response");//vActionTools.addToAction("","Body","Edit body settings","Javascript:processEdit('Body')","Read","Response");//vActionTools.addToAction("","Document","Edit ocument Layuout Settings","Javascript:processDocument('1')","Read","SubResponse");//var vBody = escape(document.forms[0].daSubform.value)	//vActionTools.addToAction("","Tools","View Current Category","Javascript:none()","Both","Main");//vActionTools.addToAction("","Basic","Basic definition edit process","Javascript:processBasic()","Read","Response");//vActionTools.addToAction("",vBody,"Basic definition edit process","Javascript:processBasic('Body-SettingsBody')","Read","Response");//vActionTools.addToAction("","Layout Settings","Basic definition edit process","Javascript:processBasic('Body-SettingsLayout')","Read","Response");//vActionTools.addToAction("","Delete","Delete document","Javascript:processEdit('Delete')","Read","Response");//vActionTools.addToAction("","List Processing","View Current Category","Javascript:viewCurrentCategory()","Both","Response");//vActionTools.addToAction("","Show Sections","List of all standard products","Javascript:showSections()","Both","Response");//vActionTools.addToAction("","Rename page","Rename page","Javascript:processEdit('Rename')","Read","Response");//vActionTools.addToAction("","Object Layout","","","Read","ObjectMenu");vActionTools.addToAction("","Tools","View Current Category","Javascript:none()","Both","Main");vActionTools.addToAction("","Refresh Page","Reload original settings on page","Javascript:window.location.reload(true)","Both","Response");vActionTools.addToAction("","Hide Editing","Hide Editing to see actual page","Javascript:hideEditor()","Read","Response");//vActionTools.addToAction("","Layout","Edit layout settings","Javascript:processEdit('Layout')","Read","Response");//vActionTools.addToAction("","Body","Edit body settings","Javascript:processEdit('Body')","Read","Response");vActionTools.addToAction("","Help","Help Menu","Javascript:None()","Read","SubMain");var vLocalAddress="/" + vDocument['Database'] +"/theHelp?openframeset"vActionTools.addToAction("",vDocument["DbTitle"],"Open Local Help","Javascript:ShowDialog('" + vLocalAddress+"','HelpWindow')","Read","SubResponse");vActionTools.addToAction("","System","Open System Help Database","Javascript:ShowDialog('/LibrarianHelp.nsf/theHelp?openframeset','HelpWindow')","Read","SubResponse");//vActionTools.addToAction("","FAQ","Open System Help By Example","Javascript:ShowDialog('/LibrarianHelp.nsf','HelpWindow')","Read","SubResponse");//ActionTools.addToAction("","Layout Settings","Basic definition edit process","Javascript:processBasic('Body-SettingsLayout')","Read","Response");//vActionTools.addToAction("","Delete","Delete document","Javascript:processEdit('Delete')","Read","Response");//vActionTools.addToAction("","Rename page","Rename page","Javascript:processEdit('Rename')","Read","Response");var vOptionvOption="Javascript:window.location='/' + vDocument['Database'] + '/theForm?OpenForm&Subform=theAttach&Layout='+ vDocument['Layout'] + '&Database='+ vDocument['LayoutDb'] +'&Resource=Image&Group=' +vDocument['Group']"vActionTools.addToAction("","Image","",vOption,"Both","Response");vOption="Javascript:window.location='/' + vDocument['Database'] + '/theForm?OpenForm&Subform=theAttach&Layout='+ vDocument['Layout'] + '&Database='+ vDocument['LayoutDb'] +'&Resource=PDF&Group=' +vDocument['Group']"vActionTools.addToAction("","PDF","",vOption,"Both","Response");//vActionTools.addToAction("","Graphics","","Javascript:none()","Both","SubMain");//vActionTools.addToAction("","Add","","Javascript:processGraphicAdd('Image','Attachment')","Both","SubResponse");//vOption="Javascript:ShowDialog('/" + vDocument['Database'] + "/theAttachmentList?readform&Type=Image&Function=Delete','Delete','500','400')"//vActionTools.addToAction("","Delete","",vOption,"Both","SubResponse");//vOption="Javascript:window.location='/' + vDocument['Database'] + '/theForm?OpenForm&Subform=theAttach&Database='+ vDocument['Database'] +'&Group=' +vDocument['Group']"//vActionTools.addToAction("","Graphics","",vOption,"Both","SubResponse");///theForm?OpenForm&Seq=6&Subform=theAttach&Database=theSourceTesting.nsf//vOption="Javascript:ShowDialog('http://localhost/snipshot.nsf/aFileUploadForm?OPENForm','Delete','500','400')"//vActionTools.addToAction("","New Graphic","",vOption,"Both","SubResponse");//vActionTools.addToAction("","PDF or File","","Javascript:none()","Both","SubMain");//vActionTools.addToAction("","Add","","Javascript:processGraphicAdd('PDF','Attachment')","Both","SubResponse");//var vOption//vOption="Javascript:ShowDialog('/" + vDocument['Database'] + "/theAttachmentList?readform&Type=PDF&Function=Delete','Delete','500','400')"//vActionTools.addToAction("","Delete","",vOption,"Both","SubResponse");if(checkPermission("[AdvancedSL]")==true)	{	vActionTools.addToAction("","View Examples","View Content Examples","Javascript:processEdit('theExamplesList')","Read","Response");	vActionTools.addToAction("","Show Document Info","Show Info","Javascript:showInfo()","Both","Response");	vActionTools.addToAction("","Show Sections","List of all standard products","Javascript:showSections()","Read","Response");	}//ShowDialog('//theAttachmentList?readform&Type=Image&Function=Delete','Delete','500','400')//vActionTools.addToAction("","Create New Root","","Javascript:none()","Read","SubMain");//vActionTools.addToAction("","Content","","Javascript:processNew('Root','thePrimaryEdit','Content')","Read","SubResponse");//vActionTools.addToAction("","Link","","Javascript:processNew('Root','theLinkEdit','Link')","Read","SubResponse");//	code:"Content",url:"Javascript:processNew('Root','thePrimaryEdit','Content')"},//          		{code:"Link",url:"Javascript:processNew('Root','theLinkEdit','Link')"}]          		///vActionTools.addToAction("","Create New","","","Read","NewRootMenu");//vActionTools.addToAction("","Body","","","Read","BodyStyleMenu");//vActionTools.addToAction("","List","","","Read","ListMenu");//vActionTools.addToAction("","List Maintenance","List Maintenance","Javascript:viewCurrentCategory()","Both","Response");//////////////////vActionTools.addToAction("","Application","View parameters and layout settings","Javascript:alert('Functionality to be developed')","Read","Response");//vActionTools.addToAction("","Layout","","","Read","LayoutMenu");return vActionTools}//function loadBody(vBodyTools)//{//return vBodyTools//}function callEmail(vPart1,vPart2) {self.location="mailto:" + vPart1 + "@" + vPart2}function printFriendlyX(){var f = document.forms[0];var vDb=vDocument["Database"]var vForm=vDocument["Form"]var vAddressif(vForm=='theForm')	{	var vDocId = vDocument["DocumentId"]	vAddress =  "/" + vDb + "/theLookupByDocumentId/" + vDocId + "!opendocument&Print=Yes"		}else	{	var vPathInfo = vDocument["PathInfo"]	if(inStr(vPathInfo,"!")>0)		{	 vAddress = vPathInfo + "&Print=Yes"				}	else if(inStr(vPathInfo,"?")>0)		{	 vAddress = vPathInfo + "&Print=Yes"				}	else		{	 vAddress = vPathInfo + "!openview&Print=Yes"	 	}	}	window.location=vAddress}function dispDate(dateVal) {DaystoAdd=dateValTodaysDate = new Date();TodaysDay = new Array('Sunday', 'Monday', 'Tuesday','Wednesday', 'Thursday', 'Friday', 'Saturday');TodaysMonth = new Array('January', 'February', 'March','April', 'May','June', 'July', 'August', 'September','October', 'November', 'December');DaysinMonth = new Array('31', '28', '31', '30', '31', '30', '31', '31', '30', '31', '30', '31');function LeapYearTest (Year) {if (((Year % 400)==0) || (((Year % 100)!=0) && (Year % 4)==0)) {return true;}else {return false;}}CurrentYear = TodaysDate.getYear();if (CurrentYear < 2000) CurrentYear = CurrentYear + 1900;currentMonth = TodaysDate.getMonth();DayOffset = TodaysDate.getDay();currentDay = TodaysDate.getDate();month = TodaysMonth[currentMonth];if (month == 'February') {if (((CurrentYear % 4)==0) && ((CurrentYear % 100)!=0) || ((CurrentYear % 400)==0)) {DaysinMonth[1] = 29;}else {DaysinMonth[1] = 28;}}days = DaysinMonth[currentMonth];currentDay += DaystoAdd;if (currentDay > days) {if (currentMonth == 11) {currentMonth = 0;month = TodaysMonth[currentMonth];CurrentYear = CurrentYear + 1}else {month =TodaysMonth[currentMonth+1];}currentDay = currentDay - days;}DayOffset += DaystoAdd;function offsettheDate (offsetCurrentDay) {if (offsetCurrentDay > 6) {offsetCurrentDay -= 6;DayOffset = TodaysDay[offsetCurrentDay-1];offsettheDate(offsetCurrentDay-1);}else {DayOffset = TodaysDay[offsetCurrentDay];return true;}}offsettheDate(DayOffset);TheDate  = DayOffset + ', ';TheDate += month + ' ';TheDate += currentDay + ', '; if (CurrentYear<100) CurrentYear="19" + CurrentYear;TheDate += CurrentYear;document.write(' '+TheDate);}function processList(vSubform){var vAddress//f = document.forms[0];var vDb=vDocument["Database"]var vLayout=vDocument["Layout"]var vDocId = vDocument["DocumentId"]var vType = vDocument["Type"]//var vBody = f.daSubform.value if(vSubform=="Root")	{	vAddress =  "/" + vDb + "/theLookupByDocumentId/" + vDocId + "?opendocument"	vAddress+="&Subform=theNavigatorEdit"	vAddress+="&Layout="+ vLayout//	Body-Process&Category=" + theType	vAddress+="&Category=" + vType + "&Type=" + vType	}else  if(vSubform=="All")	{	vAddress =  "/" + vDb + "/theAllDocuments?openview"	vAddress+="&Layout="+ vLayout//		vAddress =  "/" + vDb + "/Get" + vType + "!openview"//	vAddress+="&Layout="+ vLayout + "&Type=" + vType	}	else  if(vSubform=="Current")	{		vAddress =  "/" + vDb + "/Get" + vType + "!openview"	vAddress+="&Layout="+ vLayout + "&Type=" + vType	}		else if(vSubform!="Return")	{	vAddress =  "/" + vDb + "/theLookupByDocumentId/" + vDocId + "?opendocument"	vAddress+="&Subform="+ vSubform	vAddress+="&Layout="+ vLayout	}else	{vAddress =  "/" + vDb + "/theLookupByDocumentId/" + vDocId + "?opendocument"	}location.href= vAddress	}function adjustRightObjectWidth(tableID, widthPct,adjustAmount) {  //  execute for Opera only  //if(parseInt(navigator.appVersion)< 5//    || !navigator.userAgent.indexOf(MSIE)) return;  if(widthPct == "" || widthPct == null) widthPct = 100;  var table = document.getElementById(tableID);  if(table == null) return; // no table, nothing to do!  var body_w = document.body.clientWidth;  table.style.width = (body_w -adjustAmount) * (widthPct / 100);  }function CheckNoDocuments(vIdSection) { // function to replace the 'No documents found' messageif (typeof vIdSection=="undefined")	{vIdSection="listSection"}var vSection=document.getElementById(vIdSection)if (vSection.innerHTML.indexOf("No documents found") > 0) {	vSection.innerHTML = ""} // end if} // end functionfunction editList(vType,vDocId,vSourceId){var vDb=vDocument["Database"]var vForm=vDocument["Form"]var vAddressvAddress =  "/" + vDb + "/theLookupByDocumentId/" + vDocId + "!editDocument&SourceId=" + vSourceIdif(vType=="Settings")	{ 	vAddress+= "&Subform=theBasic&BodyEdit=theSettingsList"		}else if(vType=="Link")	{ 	vAddress+= "&Subform=theContentEditTab&BodyEdit=theLinkCommon"	+ "&Tabs=YNHHN" 	}else if(vType=="Excel")	{ 	vAddress+= "&Subform=theContentEditTab"	+ "&Tabs=YHHHH" 	}else	{ 	//vAddress+= "&Subform=theContentEdit&Field=theList"	 	 	vAddress+= "&Subform=theContentEditTab&Tabs=NYHHN&BodyEdit=theEditListOnly"		}	window.location=vAddress	}function listSubform(vSubform,vField){editListSubform(vSubform,vListId,vDocument['DocumentId'],vField)}function editListSubform(vSubform,vDocId,vSourceId,vField){var vDb=vDocument["Database"]var vForm=vDocument["Form"]var vAddressvar vSubformParamater vSubformParamater  ="&Subform=" + vSubform	var vFieldParamater if (vField=='undefined')	{vFieldParamater =""}else	{vFieldParamater ="&Field=" + vField}	vAddress =  "/" + vDb + "/theLookupByDocumentId/" + vDocId + "!editDocument&SourceId=" + vSourceIdvAddress+= vSubformParamater + vFieldParamater window.location=vAddress	}function editSpecial(vDocId){var vDb=vDocument["Database"]var vForm=vDocument["Form"]var vAddressvAddress =  "/" + vDb + "/theLookupByDocumentId/" + vDocId + "!opendocument&SourceId=" + vDocument["DocumentId"]window.location=vAddress	}function cancelForm(){	history.back()}function submitForm()	{var f=document.forms[0];	{	 f.submit();}	 }function processLink(vType,vField,vSwitchBodyStyle){var vAddress//var vSubformvar vDb=vDocument["Database"]if (vField=='undefined')	{vField="Body"}if (typeof vSwitchBodyStyle=='undefined')	{vSwitchBodyStyle=""}else if (vSwitchBodyStyle=='Promote')	{if (vDocument["PromoteTo"]=='')		{vSwitchBodyStyle=""}	else		{vSwitchBodyStyle="&BodyStyle=" +vDocument["PromoteTo"]}		}else	{vSwitchBodyStyle="&BodyStyle=" + vSwitchBodyStyle}			f = document.forms[0];var vSubject = vDocument["Subject"]var vDocId = vDocument["DocumentId"]var vBody = vDocument["Subform"]var vSuffixvAddress =  "/" + vDb + "/theLookupByDocumentId/" + vDocIdif(vType=="Link")   {    vSuffix="?editDocument&Subform=theLinkEdit"    vAddress =  vAddress + vSuffix   }           window.location=vAddress}function processLayout(vSection,vEditOpen){var vAddressif(typeof vEditOpen=='undefined')	{vEditOpen="open"}	var vSubform = "theLayout" + vSection	//f = document.forms[0];var vDb=vDocument["Database"]var vLayout=vDocument["Layout"]var vDocId = vDocument["DocumentId"]//var vBody = f.daSubform.valuevAddress =  "/" + vDb + "/GetLayout/" + vDocId + "?" + vEditOpen + "document"if(vSection!="Return")	{	vAddress+="&Subform="+ vSubform//	vAddress+="&Layout="+ vLayout	}location.href= vAddress		}function processObject(vSection){var vAddress//f = document.forms[0];var vDb=vDocument["Database"]var vLayout=vDocument["Layout"]var vDocId = vDocument["DocumentId"]//var vBody = f.daSubform.valuevAddress =  "/" + vDb + "/GetLayout/" + vDocId + "?editdocument"if(vSection!="Return")	{	vAddress+="&Subform=theLayoutEdit"	vAddress+="&Object="+ vSection	}location.href= vAddress		}function processDocument(vTab){var vAddressvar vDb=vDocument["Database"]			f = document.forms[0];var vSubject = vDocument["Subject"]var vDocId = vDocument["DocumentId"]vAddress =  "/" + vDb + "/theLookupByDocumentId/" + vDocId +"?editdocument"vAddress+="&Subform=Content_Settings&Tab=" + vTablocation.href= vAddress}var vCount=0;function listDivsHeader(vBodyStyle,vListSpan){vCount =vCount +1vRowCount=vDocument["ListColumns"];if ((vBodyStyle=="ListHeader"|vListSpan=="Yes") & vRowCount!=1)	{	 if((vCount % vRowCount)!=1)	 	{		document.write("</div></div></div>")}	document.write('<DIV class=wrapper><DIV class=listRowFull><DIV class=listBodyFull newRow>')	}else		{	if ((vCount % vRowCount)== 1| vRowCount==1) 	 { 	document.write('<DIV class=wrapper><DIV class=listRow><DIV class=listBody newRow>');	}	else 	if ((vCount % vRowCount)== 2) 	 { document.write('<DIV class=listBody>');	}	else 	if ((vCount % vRowCount)== 0) 	 { document.write('<DIV class=listBody>');	}	else	{ document.write('<DIV class=listBody>')}}}function listDivs(vBodyStyle,vListSpan){vRowCount=vDocument["ListColumns"];//vRowCount=vDocument["ListColumns"];if ((vBodyStyle=="ListHeader"|vListSpan=="Yes") & vRowCount!=1)	{	document.write('</div></div>');	vCount=0;		}else		{	 if ((vCount % vRowCount)==0)	{document.write('</div></div></div>');		}	else	{ 	document.write('</div>');		}}}function listRows(vBodyStyle,vListSpan){vRowCount=vDocument["ListColumns"];vCount=vCount+1;if(vBodyStyle=="ListHeader"|vListSpan=="Yes")	{	document.write('</td></tr><tr>')	vCount=0;	}else		{	if ((vCount % vRowCount)== 0) { document.write('</td></tr><tr>');	}	else	{ document.write('</td>')}}}function listHeader(vHeaderType){ if (vHeaderType=="SpanNoTitle")	{document.write('<td class=listHeaderTd colspan=' + vDocument["ListColumns"] + ' valign=top height=100%>')	}else	{document.write('<td class=listHeaderTd colspan=' + vDocument["ListColumns"] + ' valign=top height=100%>')	}}function displayAction(vActionType,vMainWidth,vSubWidth,vFromTop,vFromSide){var vActionResource= new theActionList()	var vActionMenu = vActionType.split(';');	var vAction	for(var vCount=0;vCount<vActionMenu.length;vCount++) {		vAction=trim(vActionMenu[vCount])		if (vAction=='Layout')			{vActionResource = loadLayoutMenu(vActionResource)}			if (vAction=='Type')			{vActionResource = loadTypeMenu(vActionResource)}				if (vAction=='S')			{vActionResource = loadSubformMenu(vActionResource)}		if (vAction=='Tools')			{vActionResource = loadTools(vActionResource)}		if (vAction=='B')			{vActionResource = loadBodyMenu(vActionResource)}			}if(typeof vMainWidth=='undefined')	{vMainWidth=90};	if(typeof vSubWidth=='undefined')	{vSubWidth=150};if(typeof vFromTop=='undefined')	{vFromTop=10	};if(typeof vFromSide=='undefined')	{vFromSide=40	};	var vEditor=checkPermission( '[Librarian]' );if (vEditor==false)	{return false}//if(vDocument["Browser"])//vActionResource=loadTypeMenu(vActionResource)if(vActionResource.List.length>0)	{	document.write("<div id=coolMenu>")	vMenuMain=writeMenu(vActionResource,vMainWidth,vSubWidth,vFromTop,vFromSide)	var m1 = new COOLjsMenuPRO("menu1", vMenuMain)	m1.initTop();	m1.init();		CLoadNotify();	//new COOLjsMenuPro("menu1", vMenuMain)	document.write("</div>")	}}function writeColumnStyle(vWidth){document.write("<style>.listTd{width:" + vWidth + ";</style>")}function popupTheMenu(vType,vEvent,vPU1,vPU2){vListId=vPU1.toUpperCase();vPopup1=vPU1.toUpperCase();if (typeof vPU2=="undefined")	{vPopup2=""}else	{vPopup2=vPU2;}	var vMousePosition=captureMousePosition(vEvent)//CMenuPopUpXY(vType,xMousePos+20,yMousePos-40)//if (vType=="popupNavigator")//	(CMenuPopUp(vType, event,-140,-20))//else	//	(CMenuPopUp(vType, event))	CMenuPopUpXY(vType,xMousePos,yMousePos)//CMenuPopUpXY(vType, 250, 550);//CMenuPopUp('popupPrimary',vEvent)//alert('xxx');//return false;//CMenuPopUp(vType, vEvent)}function callUpdateDocumentPair(vUpdatePair){updateDocumentPair(vListId,vUpdatePair)}function callProcessListGraphic(){processGraphic('list',vListId)}function callProcessEdit(){processEdit(vListId)}function callNewFromNavigator(){if(vPopup2=="")	{alert("Category does not exist yet.  Find parent document and use New-List")}else	{processNew('Navigator','ContentEdit','Content',vPopup2)}	}function callEditList(vType){editList(vType,vListId,vDocument["DocumentId"])}function callEditListDocId(vType,vDocId){editList(vType,vDocId,vDocument["DocumentId"])}function callProcessGraphic(){processGraphic('list',vListId)}function moveToDocument(){editSpecial(vListId)}function promoteList(){var vPromoteEdit="/" +vDocument['Database'] + "/theLookupByDocumentId/" + vListId + "!editDocument&Subform=theContentEditTab&Promote=Content&Tabs=NNYNN&SourceId=" + vDocument['DocumentId']window.location=vPromoteEdit}function demoteList(){	var vConfirm = confirm("Demoting a List Document will prevent you from editing or showing Primary information. You must save the following edit to make the -Demote- effective.  Do you want to contnue?")	if (vConfirm){		var vPromoteEdit="/" +vDocument['Database'] + "/theLookupByDocumentId/" + vListId + "!editDocument&Subform=theContentEditTab&BodyEdit=theEditListOnly&Promote=ListOnly&Tabs=NYHHN&SourceId=" + vDocument['DocumentId']		window.location=vPromoteEdit	}}function editSettings(vBodyEdit){if (vBodyEdit=="theSettingsList")		{		vAddress="/" +vDocument['Database'] + "/theLookupByDocumentIdBody/" + vDocument['DocumentId'] + "!editDocument&Subform=theSettingsList&Tabs=YNHHH" + "&Body=" + vDocument['BodyStyle'] 				ShowDialog(vAddress,"hilite",800,500)		}else		if (vBodyEdit=="theSettingsExcel")		{		vAddress="/" +vDocument['Database'] + "/theLookupByDocumentIdBody/" + vDocument['DocumentId'] + "!editDocument&Subform=theSettingsList&Tabs=HYHHH" + "&Body=" + vDocument['BodyStyle'] 				ShowDialog(vAddress,"hilite",800,500)		}else				{		vAddress="/" +vDocument['Database'] + "/theLookupByDocumentIdBody/" + vDocument['DocumentId'] + "!editDocument&Subform=theSettings&BodyEdit=" + vBodyEdit + "&Body=" + vDocument['BodyStyle'] 	ShowDialog(vAddress,"hilite",600,500)		}}function captureMousePosition(e) {    if (document.layers) {        // When the page scrolls in Netscape, the event's mouse position        // reflects the absolute position on the screen. innerHight/Width        // is the position from the top/left of the screen that the user is        // looking at. pageX/YOffset is the amount that the user has         // scrolled into the page. So the values will be in relation to        // each other as the total offsets into the page, no matter if        // the user has scrolled or not.        xMousePos = e.pageX;        yMousePos = e.pageY;        xMousePosMax = window.innerWidth+window.pageXOffset;        yMousePosMax = window.innerHeight+window.pageYOffset;    } else if (document.all) {  //document.body.clientWidth        // When the page scrolls in IE, the event's mouse position         // reflects the position from the top/left of the screen the         // user is looking at. scrollLeft/Top is the amount the user        // has scrolled into the page. clientWidth/Height is the height/        // width of the current page the user is looking at. So, to be        // consistent with Netscape (above), add the scroll offsets to        // both so we end up with an absolute value on the page, no         // matter if the user has scrolled or not.        xMousePos = window.event.x+document.body.scrollLeft;        yMousePos = window.event.y+document.body.scrollTop;        xMousePosMax = document.body.clientWidth+document.body.scrollLeft;        yMousePosMax = document.body.clientHeight+document.body.scrollTop;    } else if (document.getElementById) {        // Netscape 6 behaves the same as Netscape 4 in this regard         xMousePos = e.pageX;        yMousePos = e.pageY;        xMousePosMax = window.innerWidth+window.pageXOffset;        yMousePosMax = window.innerHeight+window.pageYOffset;    }}var STYLE = {	border:1,	shadow:1,	color:{		border:'#CCCCCC',		shadow:'#333333',		bgON:'white',		bgOVER:'#CCDDEE'	},	css:{		ON:'clsCMOn',		OVER:'clsCMOver'	}};function updateObject(vUpdatePairs){var vDb=vDocument["Database"]updateDocumentPair(vDocument["DocumentId"],vUpdatePairs)}function updateDocumentPair(vDocId,vUpdatePairs){var vDb=vDocument["Database"]var vAddress="/" + vDb + '/WebDynamicSave?openagent&Update=' + vUpdatePairsvAddress=vAddress +"&DocId=" + vDocId+"&ReturnId=" + vDocument["DocumentId"]window.location=vAddress}function createNewX(vType,vRelationship,vBodyStyle,vField,vSubformEdit){if (typeof vType=='undefined' | typeof vRelationship=='undefined' | typeof vBodyStyle=='undefined')	{alert("Correct format - Type,Relationship,BodyStye,Edit Subform(if different than Body Style)")	return	}	var vAddressvar vDb=vDocument["Database"]f = document.forms[0];var vDocId = vDocument["DocumentId"]var vBody = escape(vDocument["Subform"])var vLayout= escape(vDocument["Layout"])var vSuffixif (typeof vSubformEdit=='undefined')	{vSubformEdit=vBodyStyle}var vRelationshipParamater if (vRelationship=='undefined')	{vRelationshipParamater =""}else	{vRelationshipParamater ="&Relationship=" + vRelationship}var vFieldParamater if (vField=='undefined')	{vFieldParamater =""}else	{vFieldParamater ="&Field=" + vField}	vAddress =  "/" + vDb + "/theForm?OpenForm&ParentUNID=" + vDocId  + "&Layout=" + vLayout vAddress+= "&Subform=" + vSubformEdit  + "&BodyStyle=" + vBodyStylevAddress +=  vRelationshipParamater + vFieldParamater + "&SourceId=" + vDocId  +  "&Type=" + vType + "&theEnd"window.location=vAddressreturn	}function printFriendly(){document.getElementById('printFriendly').style.visibility='visible';document.getElementById('printFriendly').style.display='block';document.getElementById('vertical').style.visibility='hidden';document.getElementById('logo').style.visibility='hidden';document.getElementById('horizontal').style.visibility='hidden';document.getElementById('breadcrumb').style.visibility='hidden';document.getElementById('banner').style.visibility='hidden';//document.getElementById('footer').style.visibility='hidden';//document.getElementById('page').style.visibility='hidden';document.getElementById('body').style.left = '10px';//document.getElementById('banner').style.left = '35px';document.getElementById('page').style.width= '500px';document.getElementById('body').style.top = '40px';//document.getElementById('mivaNavigator').style.visibility='hidden';//document.getElementById('searchTable').style.visibility='hidden';}function printFriendlyUndo(){document.getElementById('vertical').style.visibility='visible';document.getElementById('logo').style.visibility='visible';document.getElementById('horizontal').style.visibility='visible';document.getElementById('breadcrumb').style.visibility='visible';document.getElementById('banner').style.visibility='visible';//document.getElementById('footer').style.visibility='visible';//document.getElementById('page').style.visibility='visible';document.getElementById('body').style.left = layoutAttribute["BodyLeft"];document.getElementById('body').style.top = layoutAttribute["BodyTop"];document.getElementById('banner').style.left = layoutAttribute["BannerLeft"];document.getElementById('page').style.width= '100%';//document.getElementById('mivaNavigator').style.visibility='visible';//document.getElementById('searchTable').style.visibility='visible';document.getElementById('printFriendly').style.visibility='hidden';}//function createNew(vFamilyType,vBodyEdit,vBodyStyle){function createNewMostRecent(vFamilyType,vBodyStyle,vField,vSubformEdit) {//Child theListEdit BodyStandardvar vAddress//var vSubformvar vDb=vDocument["Database"]f = document.forms[0];var vDocId = vDocument["DocumentId"]var vBody = escape(vDocument["Subform"])var vCategoryvar vSubject if(vFamilyType=='Child')	{	if(vDocument["ListCategory"]=='' | typeof vDocument["ListCategory"]=='undefined')		{		if(vDocument["Type"]==vDocument["Category"])			{			vCategory = escape(vDocument["Subject"])}		else			{			vCategory = escape(vDocument["Category"])}						     	vSubject = escape(vDocument["Subject"])			}		else		{		var vUnderscore = inStr(vDocument["ListCategory"],'_')		var vLength = len(vDocument["ListCategory"])				vCategory =left(vDocument["ListCategory"],vUnderscore)		var vRight=vLength - vUnderscore-1		vSubject=right(vDocument["ListCategory"],vRight)    		}	}else		{		if(vDocument["Type"]==vDocument["Category"])		{vCategory = escape(vDocument["Subject"])}	else		{vCategory = escape(vDocument["Category"])}				vSubject = escape(vDocument["Subject"])	}var vLayout= escape(vDocument["Layout"])var vSuffixvAddress =  "/" + vDb + "/theLookupByDocumentId/" + vDocIdif (typeof vSubformEdit=='undefined')	{vSubformEdit="&Subform=" + vBodyStyle}else	{vSubformEdit="&Subform=" + vSubformEdit}if (typeof vBodyStyle=='undefined')	{vBodyStyle=""}var vRelationshipParamater if (vFamilyType=='undefined')	{vFamilyType ="&FamilyType=Child"}else	{vFamilyType ="&FamilyType="+ vFamilyType}if (typeof vField=='undefined')	{vField=""}else	{vField="&Field=" + vField}	if (vSubformEdit=="RichText")	{ if (vFamilyType=='Response') 		{//vAddress='/'+ vDb + '/theFormHelpResponse?OpenForm&Subform=Body-NewRichText&Type=Help&BodyStyle=Help'		//vAddr/ess+=  "&ParentUNID=" + vDocId		vAddress= '/'+ vDb + '/theFormHelpResponse?OpenForm&ParentUNID=' + vDocId  + '&Subform=theNew&Type=Help&BodyEdit=theRichTextEdit'		}	else 		{		vAddress= '/'+ vDb + '/theFormHelp?OpenForm&ParentUNID=' + vDocId  + '&Subform=theNew&Type=Help&BodyEdit=theRichTextEdit'}	}else	{//	vAddress =  "/" + vDb + "/theForm?OpenForm&ParentUNID=" + vDocId  + "&Subject=" + vSubject + "&Category=" + vCategory + "&Layout=" + vLayout 	vAddress =  "/" + vDb + "/theForm?OpenForm&ParentUNID=" + vDocId   + "&Layout=" + vLayout //     vAddress+=vFamilyType+ "&Subform=theContentEdit" + "&BodyStyle=" + vBodyStyle + vField     vAddress+=vFamilyType+ vSubformEdit + "&BodyStyle=" + vBodyStyle+ vField//	vAddress +=  "&BodyEdit=" + vSubformEdit   + "&theEnd"		vAddress +=  "&theEnd"	}	window.location=vAddress	return	}function createNewForm(vType,vForm,vCategory,vBodyStyle,vSubformEdit,vField) {var vAddressvar vDb=vDocument["Database"]f = document.forms[0];var vLayout= escape(vDocument["Layout"])if (typeof vSubformEdit=='undefined')	{vSubformEdit="&Subform=" + vBodyStyle}else	{vSubformEdit="&Subform=" + vSubformEdit}if (typeof vBodyStyle=='undefined')	{vBodyStyle=""}if (typeof vField=='undefined')	{vField=""}else	{vField="&Field=" + vField}	vAddress =  "/" + vDb + "/" + vForm + "?OpenForm"  + "&Layout=" + vLayout vAddress+="&Type=" + vType +"&Category=" + vCategory+vSubformEdit + "&BodyStyle=" + vBodyStyle+ vFieldwindow.location=vAddressreturn	}/*   ------------------------------------------------  PVII Equal CSS Columns scripts -Version 2  Copyright (c) 2005 Project Seven Development  www.projectseven.com  Version: 2.1.0  ------------------------------------------------*/function P7_colH2(){ //v2.1.0 by PVII-www.projectseven.com var i,oh,h=0,tg,el,np,dA=document.p7eqc,an=document.p7eqa;if(dA&&dA.length){ for(i=1;i<dA.length;i+=2){dA[i+1].style.paddingBottom='';}for(i=1;i<dA.length;i+=2){ oh=dA[i].offsetHeight;h=(oh>h)?oh:h;}for(i=1;i<dA.length;i+=2){oh=dA[i].offsetHeight; if(oh<h){np=h-oh;if(!an&&dA[0]==1){P7_eqA2(dA[i+1].id,0,np);}else{ dA[i+1].style.paddingBottom=np+"px";}}}document.p7eqa=1; document.p7eqth=document.body.offsetHeight; document.p7eqtw=document.body.offsetWidth;}}function P7_eqT2(){ //v2.1.0 by PVII-www.projectseven.com if(document.p7eqth!=document.body.offsetHeight||document.p7eqtw!=document.body.offsetWidth){P7_colH2();}}function P7_equalCols2(){ //v2.1.0 by PVII-www.projectseven.com var c,e,el;if(document.getElementById){document.p7eqc=new Array(); document.p7eqc[0]=arguments[0];for(i=1;i<arguments.length;i+=2){el=null; c=document.getElementById(arguments[i]);if(c){e=c.getElementsByTagName(arguments[i+1]); if(e){el=e[e.length-1];if(!el.id){el.id="p7eq"+i;}}}if(c&&el){ document.p7eqc[document.p7eqc.length]=c;document.p7eqc[document.p7eqc.length]=el}} setInterval("P7_eqT2()",10);}}function P7_eqA2(el,p,pt){ //v2.1.0 by PVII-www.projectseven.com var sp=10,inc=20,g=document.getElementById(el);np=(p>=pt)?pt:p; g.style.paddingBottom=np+"px";if(np<pt){np+=inc; setTimeout("P7_eqA2('"+el+"',"+np+","+pt+")",sp);}}function hideEditor(){var vAddress=vDocument["PathInfo"] + "&HideEditor=Yes"location.href= vAddress	}