3v4l.org

run code in 300+ PHP versions simultaneously
<?php //if -behind- have double or more (\\) match it, but if (\) its one ignore it //get -behind\\- $str = 'hey look -behind\\- you'; //ignore -behind\- $str = 'hey look -behind\- you'; preg_match_all('/\-(.*?)(?<!\\\{2})\-/', $str, $matched); var_dump($matched);

preferences:
55.67 ms | 402 KiB | 5 Q