3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $check = '/auth/github/auth'; $url = '@/auth/(\w+)@'; var_dump(preg_match($url, $check, $matches)); var_dump($matches);
based on qDH7m
Output for 4.3.0 - 7.2.0
int(1) array(2) { [0]=> string(12) "/auth/github" [1]=> string(6) "github" }