3v4l.org

run code in 300+ PHP versions simultaneously
<?php $userid=array('123'); var_dump(addslashes(stripslashes($userid)));
Output for 8.0.1 - 8.0.30, 8.1.0 - 8.1.28, 8.2.0 - 8.2.19, 8.3.0 - 8.3.7
Fatal error: Uncaught TypeError: stripslashes(): Argument #1 ($string) must be of type string, array given in /in/KtiRJ:4 Stack trace: #0 /in/KtiRJ(4): stripslashes(Array) #1 {main} thrown in /in/KtiRJ on line 4
Process exited with code 255.
Output for 7.4.0 - 7.4.33
Warning: stripslashes() expects parameter 1 to be string, array given in /in/KtiRJ on line 4 string(0) ""

preferences:
100.04 ms | 401 KiB | 123 Q