摘要: 解决办法:将3个字节的特殊字符与emoji表情替换掉即可。$nickname = preg_replace('/xE0[x80-x9F][x80-xBF]'.'|xED[xA0-xBF][x80-xBF]/S','?', $nickname );$nickname = preg_replace('/... 阅读全文
posted @ 2015-09-15 18:24 陈朔 阅读(2687) 评论(0) 推荐(0) 编辑
摘要: //reject overly long 2 byte sequences, as well as characters above U+10000 and replace with ?$some_string = preg_replace('/[x00-x08x10x0Bx0Cx0E-x19x7F... 阅读全文
posted @ 2015-09-15 12:59 陈朔 阅读(1130) 评论(0) 推荐(0) 编辑