<mce:script type="text/javascript"><!-- function ReplaceAll(str, sptr, sptr1) { while (str.indexOf(sptr) >= 0) { str = str.replace(sptr, sptr1); } return str; } // --></mce:script> 调用示例: <mce:script type="text/javascript"><!-- var mystring="中国VB网欢迎您的光临!"; document.write("替换前:"+mystring+"<br>"); mystring=ReplaceAll(mystring,"中国VB网","http://www.chinaVB.net") document.write("替换后:"+mystring); // --></mce:script>