3v4l.org

run code in 300+ PHP versions simultaneously
<html> <head> <title></title> </head> <body> <!-- Put the body of your page below this line --> <?php //ini_set("display_errors", 1); //ini_set("track_errors", 1); //ini_set("html_errors", 1); //error_reporting(E_ALL); //The following script is tested only with servers running on Minecraft 1.7. $SERVER_IP = "69.30.205.202"; //Insert the IP of the server you want to query. $SERVER_PORT = "25565"; //Insert the PORT of the server you want to ping. Needed to get the favicon, motd, players online and players max. etc $QUERY_PORT = "25565"; //Port of query.port="" in your server.properties. Needed for the playerlist! Can be the same like the port or different. Query must be enabled in your server.properties file! $HEADS = "3D"; //"normal" / "3D" $show_max = "unlimited"; // how much playerheads should we display? "unlimited" / "10" / "53"/ ... $SHOW_FAVICON = "on"; //"off" / "on" $TITLE = "My fancy Serverpage"; $TITLE_BLOCK_ONE = "General Information"; $TITLE_BLOCK_TWO = "Players"; //////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// $ping = json_decode(file_get_contents('http://api.minetools.eu/ping/' . $SERVER_IP . '/' . $SERVER_PORT . ''), true); $query = json_decode(file_get_contents('http://api.minetools.eu/query/' . $SERVER_IP . '/' . $QUERY_PORT . ''), true); //Put the collected player information into an array for later use. if(empty($ping['error'])) { $version = $ping['version']['name']; $online = $ping['players']['online']; $max = $ping['players']['max']; $motd = $ping['description']; $favicon = $ping['favicon']; } if(empty($query['error'])) { $playerlist = $query['Playerlist']; } ?> <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title><?php echo htmlspecialchars($TITLE); ?></title> <link rel="stylesheet" href="https://netdna.bootstrapcdn.com/twitter-bootstrap/2.3.2/css/bootstrap-combined.no-icons.min.css"> <link href='http://fonts.googleapis.com/css?family=Lato:300,400' rel='stylesheet' type='text/css'> <link href="https://netdna.bootstrapcdn.com/font-awesome/3.2.1/css/font-awesome.css" rel="stylesheet"> <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/2.0.3/jquery.min.js"></script> <script type="text/javascript" src="https://netdna.bootstrapcdn.com/twitter-bootstrap/2.3.2/js/bootstrap.min.js"></script> <script language="javascript"> jQuery(document).ready(function(){ $("[rel='tooltip']").tooltip(); }); </script> <style> /*Custom CSS Overrides*/ body { font-family: 'Lato', sans-serif !important; } </style> </head> <body> <div class="container"> <h1><?php echo htmlspecialchars($TITLE); ?></h1><hr> <div class="row"> <div class="span4"> <h3><?php echo htmlspecialchars($TITLE_BLOCK_ONE); ?></h3> <table class="table table-striped"> <tbody> <tr> <td><b>IP</b></td> <td><?php echo $SERVER_IP; ?></td> </tr> <?php if(empty($ping['error'])) { ?> <tr> <td><b>Version</b></td> <td><?php echo $version; ?></td> </tr> <?php } ?> <?php if(empty($ping['error'])) { ?> <tr> <td><b>Players</b></td> <td><?php echo "".$online." / ".$max."";?></td> </tr> <?php } ?> <tr> <td><b>Status</b></td> <td><?php if(empty($ping['error'])) { echo "<i class=\"icon-ok-sign\"></i> Server is online"; } else { echo "<i class=\"icon-remove-sign\"></i> Server is offline";}?></td> </tr> <?php if(empty($ping['error'])) { ?> <?php if(!empty($favicon)) { ?> <?php if ($SHOW_FAVICON == "on") { ?> <tr> <td><b>Favicon</b></td> <td><img src='<?php echo $favicon; ?>' width="64px" height="64px" style="float:left;"/></td> </tr> <?php } ?> <?php } ?> <?php } ?> </tbody> </table> </div> <div class="span8" style="font-size:0px;"> <h3><?php echo htmlspecialchars($TITLE_BLOCK_TWO); ?></h3> <?php if($HEADS == "3D") { $url = "https://cravatar.eu/helmhead/"; } else { $url = "https://cravatar.eu/helmavatar/"; } if(empty($query['error'])) { if($playerlist != "null") { //is at least one player online? Then display it! $shown = "0"; foreach ($playerlist as $player) { $shown++; if($shown < $show_max + 1 || $show_max == "unlimited") { ?> <a data-placement="top" rel="tooltip" style="display: inline-block;" title="<?php echo $player;?>"> <img src="<?php echo $url.$player;?>/50" size="40" width="40" height="40" style="width: 40px; height: 40px; margin-bottom: 5px; margin-right: 5px; border-radius: 3px; "/></a> <?php } } if($shown > $show_max && $show_max != "unlimited") { echo '<div class="span8" style="font-size:16px; margin-left: 0px;">'; echo "and " . (count($playerlist) - $show_max) . " more ..."; echo '</div>'; } } else { echo "<div class=\"alert\" style=\"font-size:16px;\"> There are no players online at the moment!</div>"; } } else { echo "<div class=\"alert\" style=\"font-size:16px;\"> Query must be enabled in your server.properties file!</div>"; } ?> </div> </div> </div> </body> </html> <!-- Put the body of your page above this line --> </body> </html>

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.40.0070.00719.21
8.3.30.0150.00019.09
8.3.20.0040.00420.59
8.3.10.0000.00822.01
8.3.00.0090.00022.10
8.2.170.0080.00819.27
8.2.160.0090.00622.96
8.2.150.0080.00024.18
8.2.140.0040.00424.66
8.2.130.0040.00421.16
8.2.120.0000.00826.35
8.2.110.0070.00320.64
8.2.100.0040.00818.16
8.2.90.0040.00418.45
8.2.80.0060.00320.01
8.2.70.0040.00418.29
8.2.60.0000.01019.79
8.2.50.0040.00418.10
8.2.40.0000.00820.67
8.2.30.0000.00819.75
8.2.20.0040.00417.88
8.2.10.0040.00418.39
8.2.00.0040.00419.06
8.1.270.0060.00322.43
8.1.260.0040.00426.35
8.1.250.0080.00028.09
8.1.240.0030.00622.93
8.1.230.0080.00321.28
8.1.220.0040.00418.14
8.1.210.0030.00518.97
8.1.200.0040.00417.61
8.1.190.0040.00417.47
8.1.180.0040.00418.10
8.1.170.0060.00318.92
8.1.160.0050.00322.31
8.1.150.0090.00020.86
8.1.140.0060.00319.74
8.1.130.0040.00418.53
8.1.120.0000.00818.52
8.1.110.0060.00218.47
8.1.100.0020.00718.53
8.1.90.0010.00617.70
8.1.80.0000.00817.63
8.1.70.0030.00517.69
8.1.60.0000.00817.71
8.1.50.0010.00717.71
8.1.40.0020.00617.76
8.1.30.0010.00717.79
8.1.20.0020.00717.75
8.1.10.0040.00517.72
8.1.00.0010.00617.67
8.0.300.0040.00420.41
8.0.290.0000.00817.25
8.0.280.0000.00818.75
8.0.270.0000.00717.49
8.0.260.0020.00517.17
8.0.250.0040.00417.18
8.0.240.0060.00118.05
8.0.230.0060.00217.16
8.0.220.0020.00717.18
8.0.210.0040.00417.14
8.0.200.0000.00817.28
8.0.190.0000.00717.17
8.0.180.0030.00517.21
8.0.170.0010.00717.22
8.0.160.0010.00617.25
8.0.150.0090.00017.10
8.0.140.0020.00717.18
8.0.130.0040.00415.38
8.0.120.0050.00317.14
8.0.110.0000.00817.15
8.0.100.0050.00418.09
8.0.90.0020.00618.06
8.0.80.0090.00318.05
8.0.70.0070.00118.03
8.0.60.0050.00518.06
8.0.50.0050.00517.97
8.0.30.0100.00717.81
8.0.20.0110.00917.78
8.0.10.0040.00417.24
8.0.00.0110.00717.11
7.4.330.0070.00216.39
7.4.320.0040.00816.70
7.4.300.0080.00616.72
7.4.290.0150.00116.73
7.4.280.0060.00716.70
7.4.270.0100.00216.67
7.4.260.0030.00916.69
7.4.250.0040.00816.73
7.4.240.0060.00616.77
7.4.230.0050.00716.58
7.4.220.0090.00716.74
7.4.210.0070.00816.80
7.4.200.0070.00416.82
7.4.190.0140.00016.65
7.4.180.0110.00416.77
7.4.160.0090.00716.82
7.4.150.0130.00617.03
7.4.140.0080.01117.47
7.4.130.0120.00616.76
7.4.120.0080.01116.74
7.4.110.0080.00816.66
7.4.100.0130.00616.82
7.4.90.0090.00716.65
7.4.80.0030.01317.97
7.4.70.0120.00416.66
7.4.60.0100.00716.70
7.4.50.0060.00916.64
7.4.40.0110.00616.65
7.4.30.0070.00916.73
7.4.20.0110.00416.55
7.4.10.0100.00715.92
7.4.00.0130.00415.83
7.3.330.0100.00015.06
7.3.320.0080.00315.16
7.3.310.0050.00616.58
7.3.300.0070.00416.73
7.3.290.0110.00816.72
7.3.280.0120.00716.63
7.3.270.0070.01017.04
7.3.260.0090.00716.67
7.3.250.0120.00916.66
7.3.240.0100.00616.61
7.3.230.0080.00916.70
7.3.220.0000.01416.45
7.3.210.0090.00816.53
7.3.200.0090.00817.88
7.3.190.0050.01316.50
7.3.180.0130.00616.56
7.3.170.0070.00916.62
7.3.160.0120.00416.66
7.3.150.0150.00016.34
7.3.140.0100.00516.47
7.3.130.0150.00016.52
7.3.120.0110.00415.57
7.3.110.0110.00715.84
7.3.100.0050.01115.71
7.3.90.0090.00416.06
7.3.80.0130.00215.82
7.3.70.0120.00315.70
7.3.60.0080.00615.90
7.3.50.0090.00515.84
7.3.40.0090.00515.82
7.3.30.0110.00515.91
7.3.20.0130.00617.53
7.3.10.0100.00317.53
7.3.00.0110.00417.66
7.2.340.0050.01016.67
7.2.330.0070.00916.68
7.2.320.0110.00916.81
7.2.310.0120.00516.71
7.2.300.0090.00816.79
7.2.290.0080.00816.66
7.2.280.0090.00516.39
7.2.270.0120.00216.45
7.2.260.0140.00016.68
7.2.250.0110.00715.96
7.2.240.0070.01116.03
7.2.230.0120.00315.92
7.2.220.0060.01116.09
7.2.210.0090.00315.96
7.2.200.0070.01016.04
7.2.190.0070.00716.07
7.2.180.0130.00215.88
7.2.170.0120.00316.08
7.2.160.0070.00616.14
7.2.150.0110.00417.92
7.2.140.0080.00617.69
7.2.130.0120.00317.96
7.2.120.0100.00517.89
7.2.110.0150.00017.91
7.2.100.0050.00917.81
7.2.90.0080.00917.64
7.2.80.0110.00617.83
7.2.70.0070.00617.71
7.2.60.0100.00717.55
7.2.50.0070.00717.73
7.2.40.0150.00017.85
7.2.30.0110.00417.82
7.2.20.0060.00818.01
7.2.10.0040.01017.91
7.2.00.0070.00718.43
7.1.330.0070.01016.51
7.1.320.0100.00316.68
7.1.310.0090.00416.77
7.1.300.0020.01216.77
7.1.290.0100.00416.72
7.1.280.0080.00616.65
7.1.270.0060.01016.70
7.1.260.0060.00616.68
7.1.250.0130.00016.64
7.1.240.0080.00316.77
7.1.230.0060.01016.77
7.1.220.0090.00416.69
7.1.210.0080.00616.65
7.1.200.0070.00516.48
7.1.190.0050.00916.74
7.1.180.0080.00716.80
7.1.170.0070.00516.60
7.1.160.0130.00316.61
7.1.150.0070.00716.63
7.1.140.0070.00516.67
7.1.130.0070.00516.58
7.1.120.0120.00316.69
7.1.110.0090.00516.66
7.1.100.0100.00517.18
7.1.90.0060.00816.78
7.1.80.0110.00616.71
7.1.70.0050.01016.85
7.1.60.0040.01317.63
7.1.50.0100.00716.79
7.1.40.0050.00916.84
7.1.30.0120.00316.78
7.1.20.0060.00816.69
7.1.10.0100.00516.64
7.1.00.0070.03018.64
7.0.330.0050.00716.35
7.0.320.0080.00816.16
7.0.310.0080.00316.45
7.0.300.0040.00816.43
7.0.290.0100.00316.39
7.0.280.0100.00416.38
7.0.270.0070.00716.24
7.0.260.0080.00616.44
7.0.250.0080.00516.50
7.0.240.0040.01016.44
7.0.230.0070.00716.45
7.0.220.0060.00916.13
7.0.210.0090.00816.43
7.0.200.0120.00615.85
7.0.190.0070.00616.40
7.0.180.0060.00816.39
7.0.170.0090.00516.32
7.0.160.0110.00416.40
7.0.150.0080.00416.42
7.0.140.0080.00616.36
7.0.130.0110.00316.21
7.0.120.0070.00916.30
7.0.110.0050.00616.45
7.0.100.0050.02117.70
7.0.90.0100.02617.63
7.0.80.0070.03017.55
7.0.70.0070.03217.69
7.0.60.0070.03417.65
7.0.50.0220.03117.77
7.0.40.0110.02817.06
7.0.30.0060.03116.98
7.0.20.0120.02617.00
7.0.10.0080.03017.10
7.0.00.0070.03116.97
5.6.400.0090.00315.40
5.6.390.0110.00415.34
5.6.380.0090.00615.37
5.6.370.0030.00915.49
5.6.360.0070.00415.42
5.6.350.0080.00615.45
5.6.340.0070.00515.38
5.6.330.0030.01115.29
5.6.320.0030.01215.42
5.6.310.0060.00915.44
5.6.300.0080.00615.29
5.6.290.0080.00415.53
5.6.280.0060.01617.26
5.6.270.0080.00615.32
5.6.260.0080.00415.54
5.6.250.0090.02817.30
5.6.240.0090.03017.22
5.6.230.0090.02117.26
5.6.220.0080.03217.21
5.6.210.0100.02517.18
5.6.200.0080.03117.43
5.6.190.0100.03017.37
5.6.180.0110.03017.29
5.6.170.0060.02317.33
5.6.160.0080.03217.34
5.6.150.0050.02817.51
5.6.140.0060.03317.32
5.6.130.0110.02917.31
5.6.120.0100.02917.42
5.6.110.0080.03417.33
5.6.100.0090.02317.36
5.6.90.0070.03217.34
5.6.80.0090.03116.98
5.6.70.0060.03217.14
5.6.60.0100.02617.03
5.6.50.0040.03317.06
5.6.40.0080.02017.14
5.6.30.0040.03317.16
5.6.20.0080.02917.03
5.6.10.0130.02017.25
5.6.00.0070.03017.06
5.5.380.0050.03018.37
5.5.370.0100.04218.43
5.5.360.0130.04218.22
5.5.350.0160.03218.35
5.5.340.0150.03518.54
5.5.330.0120.04218.58
5.5.320.0080.04718.61
5.5.310.0120.04018.42
5.5.300.0080.04318.49
5.5.290.0080.03818.51
5.5.280.0050.04418.53
5.5.270.0120.02218.58
5.5.260.0100.04318.53
5.5.250.0100.04118.47
5.5.240.0100.04018.21
5.5.230.0100.04018.36
5.5.220.0030.04518.25
5.5.210.0080.02718.30
5.5.200.0050.04618.23
5.5.190.0130.04018.27
5.5.180.0150.03718.14
5.5.170.0040.00915.79
5.5.160.0040.04418.20
5.5.150.0060.04018.06
5.5.140.0070.04118.17
5.5.130.0100.03818.19
5.5.120.0140.02418.22
5.5.110.0110.03718.22
5.5.100.0110.04018.21
5.5.90.0100.03718.34
5.5.80.0080.03818.16
5.5.70.0120.03818.25
5.5.60.0080.02818.28
5.5.50.0050.04318.32
5.5.40.0020.04618.13
5.5.30.0150.03518.29
5.5.20.0030.04118.17
5.5.10.0050.04518.12
5.5.00.0110.03818.07

preferences:
56.52 ms | 400 KiB | 5 Q