3v4l.org

run code in 300+ PHP versions simultaneously
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <script type="text/javascript" src="js/jquery.js"></script> <script type="text/javascript" src="js/font-resize.js"></script> <script type="text/javascript"> $(document).ready(function() { fontResize(); $(window).bind('resize', function() { fontResize(); }); } ); </script> <?php function encode($string,$key) { $key = sha1($key); $strLen = strlen($string); $keyLen = strlen($key); for ($i = 0; $i < $strLen; $i++) { $ordStr = ord(substr($string,$i,1)); if ($j == $keyLen) { $j = 0; } $ordKey = ord(substr($key,$j,1)); $j++; $hash .= strrev(base_convert(dechex($ordStr + $ordKey),16,36)); } return $hash; } function decode($string,$key) { $key = sha1($key); $strLen = strlen($string); $keyLen = strlen($key); for ($i = 0; $i < $strLen; $i+=2) { $ordStr = hexdec(base_convert(strrev(substr($string,$i,2)),36,16)); if ($j == $keyLen) { $j = 0; } $ordKey = ord(substr($key,$j,1)); $j++; $hash .= chr($ordStr - $ordKey); } return $hash; } ?> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title><? echo htmlspecialchars($_GET["name"]) . '!'; ?></title> <style type="text/css"> .BIG { font-size: 1050%; font-weight: bold; font-family: "Palatino Linotype", "Book Antiqua", Palatino, serif; text-align: center; } </style> </head> <body class="BIG"> <?php $name = htmlspecialchars($_GET['name']); $urlENC = encode( $name ,"whateverkey"); $urlDEC = decode( $urlENC ,"whateverkey"); echo htmlspecialchars($_GET["url"]) . ''; //echo htmlspecialchars($_POST['name']); //echo $urlENC; ?> <br /> <? echo $urlDEC; ?> </body>

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)
8.3.60.0130.00618.55
8.3.50.0080.00922.05
8.3.40.0000.01518.97
8.3.30.0070.00719.22
8.3.20.0100.00320.25
8.3.10.0030.00520.65
8.3.00.0040.00419.51
8.2.180.0140.00416.49
8.2.170.0120.00322.96
8.2.160.0120.00319.00
8.2.150.0000.00724.18
8.2.140.0030.00724.66
8.2.130.0040.00426.16
8.2.120.0050.00220.98
8.2.110.0050.00520.29
8.2.100.0120.00018.09
8.2.90.0070.00419.19
8.2.80.0000.00817.97
8.2.70.0030.00517.63
8.2.60.0000.00818.03
8.2.50.0090.00018.07
8.2.40.0030.00518.34
8.2.30.0000.00719.31
8.2.20.0040.00417.79
8.2.10.0050.00218.00
8.2.00.0070.00017.81
8.1.280.0150.00725.92
8.1.270.0080.00022.18
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0040.00423.91
8.1.230.0090.00319.16
8.1.220.0080.00017.79
8.1.210.0000.00818.77
8.1.200.0030.01017.23
8.1.190.0000.00817.23
8.1.180.0060.00318.10
8.1.170.0040.00418.62
8.1.160.0020.00521.94
8.1.150.0000.00718.88
8.1.140.0050.00217.45
8.1.130.0000.00717.74
8.1.120.0070.00017.49
8.1.110.0040.00417.48
8.1.100.0000.00717.38
8.1.90.0000.00717.34
8.1.80.0040.00417.30
8.1.70.0040.00417.40
8.1.60.0030.00617.62
8.1.50.0030.00617.46
8.1.40.0060.00317.43
8.1.30.0000.00817.61
8.1.20.0040.00417.59
8.1.10.0000.00817.55
8.1.00.0000.00717.52
8.0.300.0070.00018.77
8.0.290.0000.00716.75
8.0.280.0070.00018.39
8.0.270.0030.00317.17
8.0.260.0030.00317.18
8.0.250.0030.00316.93
8.0.240.0000.00817.00
8.0.230.0030.00317.11
8.0.220.0030.00316.92
8.0.210.0070.00016.84
8.0.200.0030.00317.03
8.0.190.0030.00416.89
8.0.180.0040.00416.84
8.0.170.0000.00816.91
8.0.160.0000.00716.91
8.0.150.0000.00716.82
8.0.140.0040.00416.97
8.0.130.0030.00313.41
8.0.120.0040.00416.84
8.0.110.0040.00416.98
8.0.100.0050.00316.79
8.0.90.0080.00016.96
8.0.80.0120.00916.94
8.0.70.0040.00416.94
8.0.60.0040.00416.91
8.0.50.0000.00716.98
8.0.30.0140.00617.22
8.0.20.0190.00517.40
8.0.10.0030.00517.02
8.0.00.0160.01616.75
7.4.330.0000.00515.02
7.4.320.0030.00316.63
7.4.300.0030.00316.59
7.4.290.0000.00716.49
7.4.280.0030.00516.60
7.4.270.0070.00016.61
7.4.260.0070.00016.50
7.4.250.0000.00716.45
7.4.240.0020.00616.59
7.4.230.0070.00016.61
7.4.220.0120.00616.57
7.4.210.0090.00616.60
7.4.200.0000.00716.69
7.4.160.0110.00516.59
7.4.150.0160.00317.40
7.4.140.0100.00717.86
7.4.130.0090.00816.47
7.4.120.0050.01216.59
7.4.110.0130.01016.60
7.4.100.0160.00616.28
7.4.90.0110.00616.51
7.4.80.0120.00919.39
7.4.70.0130.00716.64
7.4.60.0100.01116.49
7.4.50.0000.00516.43
7.4.40.0050.01016.33
7.4.30.0060.01616.36
7.4.10.0070.01014.91
7.4.00.0080.00914.84
7.3.330.0000.00513.42
7.3.320.0000.00613.41
7.3.310.0030.00316.24
7.3.300.0070.00016.45
7.3.290.0040.01116.50
7.3.280.0080.00816.39
7.3.270.0170.00317.40
7.3.260.0040.01516.48
7.3.250.0130.00816.40
7.3.240.0110.00516.43
7.3.230.0120.00416.48
7.3.210.0110.00716.35
7.3.200.0070.01316.59
7.3.190.0090.00916.44
7.3.180.0140.00416.39
7.3.170.0080.00816.45
7.3.160.0100.01016.41
7.3.130.0090.01015.01
7.3.120.0090.00914.85
7.3.110.0090.00814.90
7.3.100.0060.00714.93
7.3.90.0050.00914.85
7.3.80.0060.00814.86
7.3.70.0030.00714.86
7.3.60.0040.00914.92
7.3.50.0090.00414.88
7.3.40.0060.00914.72
7.3.30.0060.00914.77
7.3.20.0040.00816.74
7.3.10.0060.00916.72
7.3.00.0050.00816.64
7.2.330.0030.01316.75
7.2.320.0090.01216.88
7.2.310.0140.00316.84
7.2.300.0030.01316.89
7.2.290.0080.00916.83
7.2.260.0090.00514.89
7.2.250.0090.00814.80
7.2.240.0090.00815.09
7.2.230.0070.00715.02
7.2.220.0070.00815.03
7.2.210.0040.01215.08
7.2.200.0050.00815.07
7.2.190.0090.00715.09
7.2.180.0060.00815.06
7.2.170.0060.00915.05
7.2.160.0030.00815.12
7.2.150.0040.01116.80
7.2.140.0060.01116.98
7.2.130.0070.00716.95
7.2.120.0110.00216.94
7.2.110.0080.00816.77
7.2.100.0090.00516.89
7.2.90.0030.00817.02
7.2.80.0050.00616.91
7.2.70.0070.00817.02
7.2.60.0080.00616.99
7.2.50.0050.01216.99
7.2.40.0050.00717.04
7.2.30.0070.00717.07
7.2.20.0100.00816.94
7.2.10.0050.01016.87
7.2.00.0050.00917.84
7.1.330.0040.01015.67
7.1.320.0070.00615.75
7.1.310.0090.00515.73
7.1.300.0090.00515.71
7.1.290.0030.01015.79
7.1.280.0070.00915.80
7.1.270.0040.00815.80
7.1.260.0030.00915.83
7.1.250.0080.00615.87
7.1.240.0090.00515.88
7.1.230.0100.00515.71
7.1.220.0050.00615.84
7.1.210.0050.00615.71
7.1.200.0010.01215.91
7.1.190.0030.00715.72
7.1.180.0030.01015.71
7.1.170.0050.00915.53
7.1.160.0030.00515.90
7.1.150.0050.00515.77
7.1.140.0090.00315.80
7.1.130.0040.00615.73
7.1.120.0080.00315.80
7.1.110.0070.00715.76
7.1.100.0040.00516.73
7.1.90.0070.00615.54
7.1.80.0040.00715.75
7.1.70.0020.00916.31
7.1.60.0090.00817.05
7.1.50.0100.00816.29
7.1.40.0000.01415.99
7.1.30.0090.01015.81
7.1.20.0080.00515.79
7.1.10.0020.01415.88
7.1.00.0040.03017.94
7.0.330.0050.00815.48
7.0.320.0030.01015.51
7.0.310.0050.00915.56
7.0.300.0050.01015.29
7.0.290.0030.00915.26
7.0.280.0050.00615.33
7.0.270.0050.00515.50
7.0.260.0020.01115.42
7.0.250.0030.00915.55
7.0.240.0040.00515.54
7.0.230.0050.00915.36
7.0.220.0070.00415.49
7.0.210.0020.00715.46
7.0.200.0020.01215.91
7.0.190.0080.00515.47
7.0.180.0030.01315.42
7.0.170.0050.00815.45
7.0.160.0090.00715.36
7.0.150.0110.00615.56
7.0.140.0080.02717.65
7.0.130.0050.00715.33
7.0.120.0050.00815.49
7.0.110.0230.02317.06
7.0.100.0200.01917.04
7.0.90.0220.02816.87
7.0.80.0210.02916.89
7.0.70.0220.03116.90
7.0.60.0150.02516.98
7.0.50.0160.01717.02
7.0.40.0060.02515.47
7.0.30.0030.03215.67
7.0.20.0060.02715.66
7.0.10.0050.01915.56
7.0.00.0050.03115.59
5.6.400.0060.00814.44
5.6.390.0080.00514.44
5.6.380.0050.00614.40
5.6.370.0050.00714.32
5.6.360.0070.00914.57
5.6.350.0030.00814.36
5.6.340.0040.01114.68
5.6.330.0080.00414.62
5.6.320.0040.00814.65
5.6.310.0050.00914.69
5.6.300.0070.01114.42
5.6.290.0050.00914.50
5.6.280.0050.03016.38
5.6.270.0040.00714.61
5.6.260.0030.03016.63
5.6.250.0060.02416.52
5.6.240.0070.02316.54
5.6.230.0040.03216.56
5.6.220.0030.03216.42
5.6.210.0050.01916.45
5.6.200.0040.03216.45
5.6.190.0030.02016.54
5.6.180.0080.02816.62
5.6.170.0030.01916.42
5.6.160.0080.02216.46
5.6.150.0090.03116.43
5.6.140.0080.02216.54
5.6.130.0070.01616.49
5.6.120.0090.03016.45
5.6.110.0070.02316.45
5.6.100.0040.03316.52
5.6.90.0080.02716.56
5.6.80.0060.02316.19
5.6.70.0050.03316.33
5.6.60.0020.02016.18
5.6.50.0050.03116.27
5.6.40.0080.02716.15
5.6.30.0040.02216.11
5.6.20.0040.03216.31
5.6.10.0070.02516.32
5.6.00.0040.03216.33
5.5.380.0070.02715.38
5.5.370.0020.03315.45
5.5.360.0030.01815.49
5.5.350.0070.02815.33
5.5.340.0020.02415.59
5.5.330.0070.01515.55
5.5.320.0060.03415.64
5.5.310.0060.02715.64
5.5.300.0030.02615.75
5.5.290.0100.02115.59
5.5.280.0110.01915.54
5.5.270.0080.02915.67
5.5.260.0070.01615.36
5.5.250.0030.03715.47
5.5.240.0060.02615.39
5.5.230.0050.02015.11
5.5.220.0070.03415.33
5.5.210.0050.03215.34
5.5.200.0130.02315.47
5.5.190.0070.03015.37
5.5.180.0080.03215.34
5.5.170.0080.00814.11
5.5.160.0030.02615.37
5.5.150.0070.02915.36
5.5.140.0120.01415.21
5.5.130.0080.02615.31
5.5.120.0010.02415.44
5.5.110.0030.02215.27
5.5.100.0070.02815.22
5.5.90.0040.01815.39
5.5.80.0050.02015.27
5.5.70.0080.02915.26
5.5.60.0070.03315.32
5.5.50.0060.03115.26
5.5.40.0100.02315.29
5.5.30.0100.01915.42
5.5.20.0090.01915.51
5.5.10.0030.02815.35
5.5.00.0030.02915.17
5.4.450.0080.03114.85
5.4.440.0070.02514.83
5.4.430.0050.02614.79
5.4.420.0070.03014.80
5.4.410.0060.02014.81
5.4.400.0070.01614.67
5.4.390.0040.02614.71
5.4.380.0070.02914.73
5.4.370.0070.02714.72
5.4.360.0030.02214.67
5.4.350.0060.01614.69
5.4.340.0020.02114.75
5.4.330.0030.01212.52
5.4.320.0060.03014.69
5.4.310.0060.01814.74
5.4.300.0070.02014.74
5.4.290.0090.01614.79
5.4.280.0060.02514.79
5.4.270.0030.02514.67
5.4.260.0010.03014.68
5.4.250.0060.01614.79
5.4.240.0030.02714.79
5.4.230.0030.01914.71
5.4.220.0080.01314.78
5.4.210.0090.02714.67
5.4.200.0050.02714.74
5.4.190.0030.01814.68
5.4.180.0050.02914.68
5.4.170.0030.02214.73
5.4.160.0050.01914.75
5.4.150.0060.02514.79
5.4.140.0020.02613.80
5.4.130.0020.02413.83
5.4.120.0040.03013.85
5.4.110.0080.01713.84
5.4.100.0060.02613.88
5.4.90.0060.01613.89
5.4.80.0070.02313.87
5.4.70.0050.02813.85
5.4.60.0040.03013.84
5.4.50.0060.01713.87
5.4.40.0040.03113.86
5.4.30.0070.01513.83
5.4.20.0060.02513.82
5.4.10.0080.02713.79
5.4.00.0040.02613.70
5.3.290.0070.05714.71
5.3.280.0030.06314.74
5.3.270.0100.05714.64
5.3.260.0030.04314.63
5.3.250.0130.07314.63
5.3.240.0070.08014.74
5.3.230.0070.07714.64
5.3.220.0030.05314.43
5.3.210.0070.07014.54
5.3.200.0030.07314.60
5.3.190.0100.07014.59
5.3.180.0070.05714.70
5.3.170.0030.04314.66
5.3.160.0070.07014.70
5.3.150.0070.06714.66
5.3.140.0000.08014.64
5.3.130.0100.05714.59
5.3.120.0000.07714.68
5.3.110.0070.04314.57
5.3.100.0100.07714.18
5.3.90.0030.07714.11
5.3.80.0070.04014.06
5.3.70.0070.03714.02
5.3.60.0030.03713.97
5.3.50.0100.08013.96
5.3.40.0000.06313.98
5.3.30.0000.07313.94
5.3.20.0100.04313.78
5.3.10.0070.06713.66
5.3.00.0030.05313.68
5.2.170.0030.06012.09
5.2.160.0070.05712.09
5.2.150.0030.03012.09
5.2.140.0070.05712.09
5.2.130.0000.05012.09
5.2.120.0030.03012.09
5.2.110.0000.04712.09
5.2.100.0070.05012.09
5.2.90.0070.05312.09
5.2.80.0000.07012.09
5.2.70.0000.06312.09
5.2.60.0000.03712.09
5.2.50.0130.05312.09
5.2.40.0100.04012.09
5.2.30.0070.05312.09
5.2.20.0000.04312.09
5.2.10.0030.05012.09
5.2.00.0000.03012.09
5.1.60.0070.02012.09
5.1.50.0000.07312.09
5.1.40.0000.03012.09
5.1.30.0030.05712.09
5.1.20.0070.02712.09
5.1.10.0000.04712.09
5.1.00.0000.02712.09
5.0.50.0100.01712.09
5.0.40.0030.02012.09
5.0.30.0130.02312.09
5.0.20.0000.03012.09
5.0.10.0100.03712.09
5.0.00.0030.05712.09
4.4.90.0030.03312.09
4.4.80.0000.03012.09
4.4.70.0030.02012.09
4.4.60.0000.02012.09
4.4.50.0030.03012.09
4.4.40.0000.04712.09
4.4.30.0000.02712.09
4.4.20.0000.01312.09
4.4.10.0030.01012.09
4.4.00.0030.02012.09
4.3.110.0000.02012.09
4.3.100.0000.01712.09
4.3.90.0000.02312.09
4.3.80.0000.05312.09
4.3.70.0030.03012.09
4.3.60.0000.03712.09
4.3.50.0000.02712.09
4.3.40.0030.04712.09
4.3.30.0070.03012.09
4.3.20.0030.03312.09
4.3.10.0000.02712.09
4.3.00.0030.02012.09

preferences:
38.39 ms | 401 KiB | 5 Q