正则表达式1、替换“/\d/”,“#”,$str:正则表达式\d数字,替换为#,字符串$str="2hello5li6lei";echopreg_replace("/\d/","#",$str);2、拆分正则表达式,字符串$str="2hello5li6lei";var_dump(preg_split("/\d/",$str));3、匹配所有满足正则的字符串$str="2hello5li6lei";preg_match_all("/\d",$str,$arr);//正则表达式,定义的字符串...
查看全文