3v4l.org

run code in 300+ PHP versions simultaneously
<?php $allowed = array('txt', 'docx'); print "\n\$_REQUEST:"; var_dump($_REQUEST); o$a="txt.$php"; echo "test${a}test\n"; if (isset($_REQUEST['zzfile'])) { $zzfile = $_REQUEST['zzfile']; //$filename = basename($zzfile); $filename = $zzfile; print "\nfilename:\n"; var_dump($filename); if (preg_match('#\.(.+)$#', $filename, $matches) && isset($matches[1]) && !in_array($matches[1], $allowed)) die("Extension ${matches[1]} is not allowed!"); echo "\nmatches:"; var_dump($matches); preg_match('#.#', $filename, $met); print("\nmet:\n"); var_dump($met); if (strrpos($filename, '.') !== false) //zwraca od pierwszej kropki od prawej do konca + end $ext = substr($filename, strrpos($filename, '.')); else $ext = ''; $newfile = "flag$ext"; echo "Reading <strong>$newfile</strong>..."; // Hint: the flag is in flag.php echo '<pre>'; readfile($newfile); echo '</pre>'; } ?>

Here you find the average performance (time & memory) of each version. A grayed out version indicates it didn't complete successfully (based on exit-code).

VersionSystem time (s)User time (s)Memory (MiB)
7.1.60.0230.00034.81
7.1.50.0170.00734.62
7.1.40.0200.01334.45
7.1.30.0200.01334.32
7.1.20.0130.02034.52
7.1.10.0800.00314.49
7.1.00.0000.01016.51
7.0.200.0030.00716.54
7.0.190.0070.00316.59
7.0.180.0130.00316.11
7.0.170.0070.01016.04
7.0.160.0000.01315.99
7.0.150.0730.00313.98
7.0.140.0970.00714.35
7.0.130.0770.01014.43
7.0.120.0600.01714.43
7.0.110.0630.00714.22
7.0.100.0630.00716.05
7.0.90.0000.01716.29
7.0.80.0000.01016.35
7.0.70.0070.00715.93
7.0.60.0000.01316.00
7.0.50.0000.01016.28
7.0.40.0000.01016.41
7.0.30.0030.00716.34
7.0.20.0030.00716.23
7.0.10.0000.01016.22
7.0.00.0070.00316.24

preferences:
139.39 ms | 1394 KiB | 7 Q