rem: this.replace=function(sId,sAttribute,sSearch,sReplace){var bFunction=false;if(sAttribute=="innerHTML") sSearch=this.getBrowserHTML(sSearch);eval("var txt=document.getElementById('"+sId+"')."+sAttribute);if(typeof txt=="function"){txt=txt.toString();bFunction=true;} if(txt.indexOf(sSearch)>-1){var newTxt='';while(txt.indexOf(sSearch)>-1){x=txt.indexOf(sSearch)+sSearch.length+1;newTxt+=txt.substr(0,x).replace(sSearch,sReplace);txt=txt.substr(x,txt.length-x);} newTxt+=txt;if(bFunction){eval("newTxt ="+newTxt);eval('this.$("'+sId+'").'+sAttribute+'=newTxt;');} else if(this.willChange(sId,sAttribute,newTxt)){eval('this.$("'+sId+'").'+sAttribute+'=newTxt;');} } } 
add: this.replace = function(sId,sAttribute,sSearch,sReplace) { var bFunction = false;  if (sAttribute == "innerHTML") sSearch = this.getBrowserHTML(sSearch);  eval("var txt=document.getElementById('"+sId+"')."+sAttribute); if (typeof txt == "function") { txt = txt.toString(); bFunction = true; } if (txt.indexOf(sSearch)>-1) { var newTxt = ''; while (txt.indexOf(sSearch) > -1) { x = txt.indexOf(sSearch)+sSearch.length+1; newTxt += txt.substr(0,x).replace(sSearch,sReplace); txt = txt.substr(x,txt.length-x); } newTxt += txt; if (bFunction) { eval("newTxt =" + newTxt); eval('this.$("'+sId+'").'+sAttribute+'=newTxt;'); } else if (this.willChange(sId,sAttribute,newTxt)) { eval('this.$("'+sId+'").'+sAttribute+'=newTxt;'); } } } 
context: this.replace=function(sId,sAttribute,sSearch,sReplace){var bFunction=false;if(sAttribute=="innerHTML")sSearch=this.getBrowserHTML(sSearch);eval("var txt=document.getElementById('"+sId+"')."+sAttribute);if(typeof txt=="function"){txt=txt.toString();bFunction=true;}if(txt.indexOf(sSearch)>-1){var newTxt='';while(txt.indexOf(sSearch)>-1){x=txt.indexOf(sSearch)+sSearch.length+1;newTxt+=txt.substr(0,x).replace(sSearch,sReplace);txt=txt.substr(x,txt.length-x);}newTxt+=txt;if(bFunction){eval("newTxt ="+newTxt);eval('this.$("'+sId+'").'+sAttribute+'=newTxt;');}else if(this.willChange(sId,sAttribute,newTxt)){eval('this.$("'+sId+'").'+sAttribute+'=newTxt;');}}}
meta: 8936	/local1/tlutelli/issta_data/temp/all_js/javascript/2006_temp/2006/8936/eec59bc291abab488d492ab49f32f1bb86259f41/xajax.js/clean/trunk/3dparty/xajax/xajax_js/xajax.js