正則中的Named Subpattern 版本差別

Example #4 Using named subpattern php <?php $str  =  'foobar: 2008' ; preg_match ( '/(?<name>/w+): (?<digit>/d+)/' ,  $str ,  $matches ); print_r ( $matches ); ?> The above example will output:git Arr
相關文章
相關標籤/搜索