php preg_match 和preg_match_all
2014-02-27 22:51 youxin 阅读(289) 评论(0) 收藏 举报
$h3=trim('【我要变强】【主流程】整体功能测试点');
$matches=array();
preg_match_all('/【(.+?)】/', $h3,$matches);
print_r($matches);
Array ( [0] => Array ( [0] => 【我要变强】 [1] => 【主流程】 ) [1] => Array ( [0] => 我要变强 [1] => 主流程 ) )
http://www.5idev.com/p-php_preg_match.shtml
http://www.chinahtml.com/1007/php-127924631319354.html
http://www.cnblogs.com/baochuan/archive/2012/03/12/2391135.html
http://www.jb51.net/article/9387.htm
浙公网安备 33010602011771号