3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $str = 'abc abc abc'; preg_match_all("/a/", $str, $m, PREG_OFFSET_CAPTURE); print_r($m);
Output for 5.3.20 - 7.2.0
Array ( [0] => Array ( [0] => Array ( [0] => a [1] => 0 ) [1] => Array ( [0] => a [1] => 4 ) [2] => Array ( [0] => a [1] => 8 ) ) )