<?php//请修改变量p的正则表达式,使他能够匹配str中的电话$p = '/\d+\-\d+/';$str = "234123我的2-123电话是010-12345678";preg_match($p, $str, $match);echo $match[1];?>
我想数组中储存010-12345678,怎么修改正则表达式