3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $attr = '@C_1_2=Client'; $d = 'C_1_2: Client'; if (preg_match('/\@(.*)=(.*)/', $attr, $matches)) { // check corresponding values $tmp_attr = trim($matches[1]); $tmp_value = trim($matches[2]); if (preg_match("/$tmp_attr:$tmp_value/", $d)) { echo 'yes'; } }
based on ZCoYV
Output for 5.6.0 - 5.6.30, hhvm-3.15.4, 7.0.0 - 7.3.0beta1