日期:2014-05-16 浏览次数:20544 次
$a = "'你好(39)','你好啊(60)','他好(52)','他好啊(23)','我好(80)','我好啊(99)'";
$a = "'你好(39)','你好啊(60)','他好(52)','他好啊(23)','我好(80)','我好啊(99)'";
$arr = explode('\',\'', trim($a, '\''));
$newArr = array();
foreach ($arr as &$value) {
if (preg_match('/[\d]+/', $value, $match)) {
if (isset($match[0])) {
if ($match[0] > 50) {
$newArr[] = '\''.$value.'\'';
}
}
}
}
echo '"'.implode(',',$newArr).'"';