$p = '/(\w+\s\w+)/';//加括号,$match有两个
$n ='/\w+\s\w+/';//不加括号,$mctch有就只有一个
$str = "name:steven jobs";
preg_match($p, $str, $match);
preg_match($n, $str, $mctch);
print_r($match);
echo "<br/>";
print_r($mctch);
Array ( [0] => steven jobs [1] => steven jobs )
Array ( [0] => steven jobs )
pardon110