3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $row = array ( "phone_number" => "9088886655", "phone_number_2" => NULL, "phone_number_3" => NULL ); if(empty($row['phone_number']) && empty($row['phone_number_2']) && empty($row['phone_number_3'])) print('yf1'.PHP_EOL); if(!empty($row['phone_number']) && !check_phone($row['phone_number'])) print('yf2'.PHP_EOL); if(!empty($row['phone_number_2']) && !check_phone($row['phone_number_2'])) print('yf3'.PHP_EOL); if(!empty($row['phone_number_3']) && !check_phone($row['phone_number_3'])) print('yf4'.PHP_EOL); function check_phone($v) { print('y'.$v.PHP_EOL); }
Output for 4.3.10 - 4.4.9, 5.0.2 - 7.1.0
y9088886655 yf2
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/ZE5La on line 18 y9088886655PHP_EOL Notice: Use of undefined constant PHP_EOL - assumed 'PHP_EOL' in /in/ZE5La on line 11 yf2PHP_EOL