3v4l.org

run code in 300+ PHP versions simultaneously
<?php $filename = '1234_56_78 A_FAIRLY_SHORT_TITLE_D.pdf'; preg_match('~([^ _]+)[ _]([^ _]+)[ _]([^ _]+)[ _](.+)[ _](\S)~', pathinfo($filename, PATHINFO_FILENAME), $m); var_export([ 'project_no' => $m[1], 'series_no' => $m[2], 'sheet_no' => $m[3], 'title' => str_replace('_', ' ', $m[4]), 'revision' => $m[5], ]);
Output for git.master, git.master_jit, rfc.property-hooks
array ( 'project_no' => '1234', 'series_no' => '56', 'sheet_no' => '78', 'title' => 'A FAIRLY SHORT TITLE', 'revision' => 'D', )

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
82.3 ms | 405 KiB | 5 Q