3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $str = 'Bot draws - nino: (JH)'; preg_match("#^Bot draws - ([a-z0-9\-\._]+)\: ?(\((.*)\))?$#i",$str,$match); if ( is_array($match) && isset($match[0]) && count($match[0]) > 0 ) { foreach ( $match[0] as $key=>$val ) { $$match[1][$key] = create_function($match[2][$key],$match[3][$key]); } } echo $Matches;
Output for 5.0.4 - 7.1.0
Warning: Invalid argument supplied for foreach() in /in/athet on line 5 Notice: Undefined variable: Matches in /in/athet on line 9
Output for 4.3.0 - 4.3.10, 4.4.0 - 5.0.3
Warning: Invalid argument supplied for foreach() in /in/athet on line 5 Notice: Undefined variable: Matches in /in/athet on line 9
Output for 4.3.11
Notice: Undefined variable: Matches in /in/athet on line 9