3v4l.org

run code in 300+ PHP versions simultaneously
<?php $process = array("as12"=>"deleted","as13"=>1,"as14"=>1); if(!in_array(0, $process)) echo "success"; else echo "not success"; //It's outputting "not success"; var_dump(in_array(0, $process)); //Output : null var_dump(in_array(0, $this->tProcessActions) === true); ///Output : true
Output for 8.0.0 - 8.0.30, 8.1.0 - 8.1.28, 8.2.0 - 8.2.18, 8.3.0 - 8.3.6
successbool(false) Fatal error: Uncaught Error: Using $this when not in object context in /in/noI5S:14 Stack trace: #0 {main} thrown in /in/noI5S on line 14
Process exited with code 255.
Output for 7.0.0 - 7.0.20, 7.1.0 - 7.1.20, 7.2.0 - 7.2.33, 7.3.12 - 7.3.33, 7.4.0 - 7.4.33
not successbool(true) Fatal error: Uncaught Error: Using $this when not in object context in /in/noI5S:14 Stack trace: #0 {main} thrown in /in/noI5S on line 14
Process exited with code 255.
Output for 5.2.3 - 5.2.17, 5.3.0 - 5.3.29, 5.4.0 - 5.4.45, 5.5.0 - 5.5.35, 5.6.0 - 5.6.28
not successbool(true) Fatal error: Using $this when not in object context in /in/noI5S on line 14
Process exited with code 255.
Output for 5.0.0 - 5.0.5, 5.1.1 - 5.1.6, 5.2.0 - 5.2.2
not successbool(true) <br /> <b>Fatal error</b>: Using $this when not in object context in <b>/in/noI5S</b> on line <b>14</b><br />
Process exited with code 255.
Output for 5.1.0
<br /> <b>Fatal error</b>: fatal flex scanner internal error--end of buffer missed in <b>/in/noI5S</b> on line <b>15</b><br />
Process exited with code 255.
Output for 4.4.3 - 4.4.9
not successbool(true) <br /> <b>Warning</b>: in_array() [<a href='function.in-array'>function.in-array</a>]: Wrong datatype for second argument in <b>/in/noI5S</b> on line <b>14</b><br /> bool(false)
Output for 4.3.2 - 4.3.11, 4.4.0 - 4.4.2
not successbool(true) <br /> <b>Warning</b>: in_array(): Wrong datatype for second argument in <b>/in/noI5S</b> on line <b>14</b><br /> bool(false)
Output for 4.3.0 - 4.3.1
not successbool(true) <br /> <b>Warning</b>: in_array() [<a href='http://www.php.net/function.in-array'>function.in-array</a>]: Wrong datatype for second argument in <b>/in/noI5S</b> on line <b>14</b><br /> bool(false)

preferences:
238.56 ms | 402 KiB | 345 Q