标签:logs span class 过滤 sub return str amp remove
//过滤特殊字符 function removeSpecial(s) { var rs = ""; for (var i = 0; i < s.length; i++) { rs += s.substr(i, 1).replace(/[{}|“:?》《【】’;、。,”\]\[{}|":?><‘;\/.,·!¥……()——=`\-~!@#$%^&*()_+]/g, ‘‘); } return rs; }
标签:logs span class 过滤 sub return str amp remove
原文地址:http://www.cnblogs.com/lunachen/p/7224750.html