摘要:
从网上大概的搜了一下关于这个问题的解答大致有两种解决办法方法1:functiongetBytesCount(str){varbytesCount =0;if(str !=null) {for(vari =0; i < str.length; i++) {varc = str.charAt(i);if(/^[/u0000-/u00ff]$/.test(c)) { bytesCount +=1; }else { bytesCount +=2; }... 阅读全文
posted @ 2008-10-07 10:26
icewolf29
阅读(125)
评论(0)
推荐(0)

浙公网安备 33010602011771号