// SEARCH FOR A TERM IN A TARGET STRING AND REPLACE IT//// replace(target, oldTerm, newTerm, caseSensitive, wordOrSubstring)//// where caseSenstive is a boolean value and wordOrSubstring is a boolean// value and true means whole words, false means substrings//function replace(target, oldTerm, newTerm, caseSens, wordOnly) {	var work = target;	var ind = 0;	var next = 0;   	if (!caseSens) {		oldTerm = oldTerm.toLowerCase();		work = target.toLowerCase();	}   	while ((ind = work.indexOf(oldTerm,next)) >= 0) {		if (wordOnly) {			var before = ind - 1;			var after = ind + oldTerm.length;			if (!(space(work.charAt(before)) && space(work.charAt(after)))) {				next = ind + oldTerm.length;				continue;			}		}		target = target.substring(0,ind) + newTerm + target.substring(ind+oldTerm.length,target.length);		work = work.substring(0,ind) + newTerm + work.substring(ind+oldTerm.length,work.length);		next = ind + newTerm.length;		if (next >= work.length) { break; }	}	return target;}function popUp(URL) {	day = new Date();	id = day.getTime();	eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=1,statusbar=0,menubar=0,resizable=1,width=450,height=600,left = 287,top = 84');");}// This is the popUp function that opens a larger windowfunction popUp2(URL) {	day = new Date();	id = day.getTime();	eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=1,statusbar=0,menubar=0,resizable=1,width=600,height=600,left = 100,top = 25');");}// This is the popUp function that opens a larger window with toolbarsfunction popUp4(URL) {	day = new Date();	id = day.getTime();	eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=1,statusbar=0,menubar=1,resizable=1,width=800,height=600,left = 100,top = 25');");}// This is the popUp function that opens a window (for PDP) w/ scrollbarsfunction popUp3(URL) {	day = new Date();	id = day.getTime();	eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=1,statusbar=0,menubar=0,resizable=1,width=600,height=600,left = 100,top = 25');");}function saveCheckboxes() {	var fm = document.forms[0];    	var the = document.getElementById('getFileSaveCode').getAttribute('onClick').toString();    	start = the.indexOf('_doClick');	var end = the.indexOf(', this');  	_doClick(the.substring(start + 10,end - 1), this, null)}function MM_jumpMenu(targ,selObj,restore,loc){ //v3.0 	eval(targ+".location=loc + 'home?OpenForm&Group="+selObj.options[selObj.selectedIndex].value+"'");  	if (restore) selObj.selectedIndex=0;}