3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $string = '  love@outerbanks.org  '; preg_match('/^\x{c2a0}*(.*?)\x{c2a0}*$/u', $string, $out); var_dump($out[1]); foreach ($out[1] as $chr) { echo ord($chr); }
based on CfltQ
Output for 4.3.3 - 4.3.10, 4.4.0 - 7.1.7
string(27) "  love@outerbanks.org  " Warning: Invalid argument supplied for foreach() in /in/4MAi1 on line 8
Output for 4.3.11
string(27) "  love@outerbanks.org  "
Output for 4.3.0 - 4.3.2
Notice: Undefined offset: 1 in /in/4MAi1 on line 6 NULL Warning: Invalid argument supplied for foreach() in /in/4MAi1 on line 8