3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $name='/home/a/akatava/public_html/tmp/order_777777.xls'; $fileName = basename($name); $newName = str_replace($fileName, '', $name); echo $newName.PHP_EOL.$fileName;
Output for 4.3.10 - 4.4.9, 5.0.2 - 7.1.0
/home/a/akatava/public_html/tmp/ order_777777.xls
Output for 4.3.0 - 4.3.9, 5.0.0 - 5.0.1
Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/d4PmT on line 7 /home/a/akatava/public_html/tmp/PHP_EOLorder_777777.xls