3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php var_dump( array_filter( array( 45, '15', "'; -- \DROP TABLE alerts;", 1, 2, '3', 4 ), is_numeric ) );
Output for 7.2.0 - 7.3.0rc3
Warning: Use of undefined constant is_numeric - assumed 'is_numeric' (this will throw an Error in a future version of PHP) in /in/LK6b8 on line 2 array(6) { [0]=> int(45) [1]=> string(2) "15" [3]=> int(1) [4]=> int(2) [5]=> string(1) "3" [6]=> int(4) }
Output for 5.6.30, hhvm-3.15.4 - 3.21.3, 7.0.0 - 7.1.21
Notice: Use of undefined constant is_numeric - assumed 'is_numeric' in /in/LK6b8 on line 2 array(6) { [0]=> int(45) [1]=> string(2) "15" [3]=> int(1) [4]=> int(2) [5]=> string(1) "3" [6]=> int(4) }
Output for hhvm-3.22.0
Notice: Use of undefined constant is_numeric - assumed 'is_numeric' in /in/LK6b8 on line -1 array(6) { [0]=> int(45) [1]=> string(2) "15" [3]=> int(1) [4]=> int(2) [5]=> string(1) "3" [6]=> int(4) }