3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $file_name = '\\foo\\bar\\baz'; $file_name = 'baz'; $ext = substr( strrchr($file_name, '\\'), 1); echo $ext;
based on Ovd9a
Output for 5.6.38 - 7.3.0rc3