3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $user=False; $p=array(); $a=array("ppp"); var_dump($a==TRUE); var_dump($a==FALSE); var_dump($a==1); var_dump($a==0); var_dump($a==-1); var_dump($a=="1"); var_dump($a=="0"); var_dump($a=="-1"); var_dump($a==NULL); var_dump($a==$p); var_dump($a=="ppp"); var_dump($a==""); var_dump($a==array("ppp")); var_dump(mysql_num_rows(True));
Output for 7.0.0 - 7.1.0
bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) Fatal error: Uncaught Error: Call to undefined function mysql_num_rows() in /in/vHkJE:18 Stack trace: #0 {main} thrown in /in/vHkJE on line 18
Process exited with code 255.
Output for hhvm-3.10.0 - 3.12.0
bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) Warning: mysql_num_rows() expects parameter 1 to be resource, boolean given in /in/vHkJE on line 18 NULL
Output for 5.2.3 - 5.6.28
bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) Fatal error: Call to undefined function mysql_num_rows() in /in/vHkJE on line 18
Process exited with code 255.
Output for 5.0.0 - 5.2.2
bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) <br /> <b>Fatal error</b>: Call to undefined function mysql_num_rows() in <b>/in/vHkJE</b> on line <b>18</b><br />
Process exited with code 255.
Output for 4.3.0 - 4.4.9
bool(true) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(false) bool(true) <br /> <b>Warning</b>: mysql_num_rows(): supplied argument is not a valid MySQL result resource in <b>/in/vHkJE</b> on line <b>18</b><br /> NULL