"pppppp",2=>"他他他",3=>"aaaaa",4=>"你你你")如何将éé转化为英文我的最终目的就是分类成这样.ééopp,pppppp,aaaaa他他他,你你你------解决方案--------------------$a&nbs"/> "pppppp",2=>"他他他",3=>"aaaaa",4=>"你你你")如何将éé转化为英文我的最终目的就是分类成这样.ééopp,pppppp,aaaaa他他他,你你你------解决方案--------------------$a&nbs">

怎么对英文与汉字进行判断

WBOY
Release: 2016-06-13 12:00:15
Original
867 people have browsed it

如何对英文与汉字进行判断
如一组数据$a=array(0=>"ééopp",1=>"pppppp",2=>"他他他",3=>"aaaaa",4=>"你你你")

如何将éé转化为英文

我的最终目的就是分类成这样.
ééopp,pppppp,aaaaa

他他他,你你你


------解决方案--------------------

$a = array(0=>"ééopp",1=>"pppppp",2=>"他他他",3=>"aaaaa",4=>"你你你");<br />$t = preg_grep('/\w/', $a);<br />echo join(',', $t), PHP_EOL;<br />echo join(',', array_diff($a, $t));<br />
Copy after login
ééopp,pppppp,aaaaa
他他他,你你你

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template