3v4l.org

run code in 300+ PHP versions simultaneously
<?php $imageTag = '<img src = http://nycxplorer.com/wp-content/uploads/2012/02/bagel1-1.jpg height="300" width="200">'; //remove all whitespace from within and around the src portion //$imageTag = trim(preg_replace('/[\s]+/','', $imageTag)); //print_r($imageTag . "\n"); //grab the src portion of the image tag $srcPattern = "/src\s*?=\s*?\S+(\s|>)/s"; preg_match($srcPattern, $imageTag, $srcParts); $srcPart = $srcParts[0]; print_r($srcPart. "\n"); //grab the src URL $oldUrl = substr($srcPart, 4); //if there are quotes at the beginning of the url, cut them off if(strpos($oldUrl, '"') == 0 || strpos($oldUrl, "'") == 0) { $oldUrl = substr($oldUrl, 1, strlen($oldUrl)-2); } print_r($oldUrl. "\n"); ?>

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.0070.00716.63
8.3.50.0140.00316.62
8.3.40.0040.01119.09
8.3.30.0110.00319.02
8.3.20.0080.00018.90
8.3.10.0060.00320.83
8.3.00.0000.00817.75
8.2.180.0070.01416.88
8.2.170.0090.00622.96
8.2.160.0150.00422.22
8.2.150.0050.00324.18
8.2.140.0070.00024.66
8.2.130.0030.00526.16
8.2.120.0090.00020.14
8.2.110.0000.00921.23
8.2.100.0080.00318.03
8.2.90.0000.00919.21
8.2.80.0050.00318.05
8.2.70.0030.00617.88
8.2.60.0040.00418.02
8.2.50.0040.00418.07
8.2.40.0000.00718.34
8.2.30.0070.00018.24
8.2.20.0000.00717.77
8.2.10.0040.00417.80
8.2.00.0000.00717.98
8.1.280.0180.00325.92
8.1.270.0050.00324.66
8.1.260.0040.00426.35
8.1.250.0070.00028.09
8.1.240.0090.00020.89
8.1.230.0090.00321.03
8.1.220.0040.00417.74
8.1.210.0030.00518.77
8.1.200.0030.00617.60
8.1.190.0030.00517.52
8.1.180.0040.00418.10
8.1.170.0040.00419.02
8.1.160.0000.00718.93
8.1.150.0000.00718.68
8.1.140.0040.00417.68
8.1.130.0070.00017.76
8.1.120.0000.00717.62
8.1.110.0040.00417.61
8.1.100.0000.00817.53
8.1.90.0000.00817.51
8.1.80.0000.00817.54
8.1.70.0030.00317.59
8.1.60.0060.00317.83
8.1.50.0060.00317.55
8.1.40.0050.00317.58
8.1.30.0050.00317.66
8.1.20.0000.00817.75
8.1.10.0040.00417.75
8.1.00.0050.00317.57
8.0.300.0040.00420.11
8.0.290.0040.00416.74
8.0.280.0030.00318.50
8.0.270.0030.00317.20
8.0.260.0000.00817.00
8.0.250.0070.00017.07
8.0.240.0000.00717.11
8.0.230.0030.00317.15
8.0.220.0000.00717.09
8.0.210.0000.00617.11
8.0.200.0030.00317.11
8.0.190.0000.00817.09
8.0.180.0000.00717.12
8.0.170.0060.00316.96
8.0.160.0050.00217.08
8.0.150.0040.00416.98
8.0.140.0090.00316.96
8.0.130.0000.00613.48
8.0.120.0000.00817.00
8.0.110.0000.00817.10
8.0.100.0030.00316.98
8.0.90.0040.00417.03
8.0.80.0040.01117.02
8.0.70.0070.00016.97
8.0.60.0080.00016.92
8.0.50.0040.00417.10
8.0.30.0100.00917.19
8.0.20.0120.01517.34
8.0.10.0000.00817.08
8.0.00.0120.01016.89
7.4.330.0060.00013.20
7.4.320.0060.00316.85
7.4.300.0030.00316.80
7.4.290.0040.00416.64
7.4.280.0060.00316.89
7.4.270.0030.00316.68
7.4.260.0030.00313.52
7.4.250.0000.01016.78
7.4.240.0030.00316.84
7.4.230.0030.00316.91
7.4.220.0070.02016.71
7.4.210.0080.00816.85
7.4.200.0030.00516.93
7.4.190.0070.00016.80
7.4.160.0060.01016.70
7.4.150.0090.00916.68
7.4.140.0110.00816.79
7.4.130.0080.01216.61
7.4.120.0120.00516.82
7.4.110.0100.00716.72
7.4.100.0090.00916.73
7.4.90.0140.01116.71
7.4.80.0040.01416.67
7.4.70.0100.00616.86
7.4.60.0230.00016.93
7.4.50.0030.00316.75
7.4.40.0030.01316.74
7.4.30.0060.00916.78
7.4.00.0030.00915.39
7.3.330.0000.00613.21
7.3.320.0030.00313.39
7.3.310.0030.00316.43
7.3.300.0070.00016.49
7.3.290.0060.01316.59
7.3.280.0050.01116.47
7.3.270.0110.01216.60
7.3.260.0160.00316.64
7.3.250.0110.01016.54
7.3.240.0170.00316.56
7.3.230.0090.00916.67
7.3.210.0140.00316.51
7.3.200.0000.02019.39
7.3.190.0080.01616.85
7.3.180.0080.00816.75
7.3.170.0190.00616.77
7.3.160.0090.00616.84
7.3.120.0000.01514.83
7.2.330.0140.00316.97
7.2.320.0030.01316.72
7.2.310.0100.01016.80
7.2.300.0060.01016.80
7.2.290.0060.01216.91
7.2.00.0060.00919.91
7.1.100.0070.00417.97
7.1.70.0040.00417.07
7.1.60.0090.01519.40
7.1.50.0070.01417.22
7.1.00.0000.08022.31
7.0.200.0050.00216.83
7.0.140.0030.07322.20
7.0.120.0000.06022.16
7.0.60.0100.06319.87
7.0.50.0130.05317.91
7.0.40.0070.04020.00
7.0.30.0470.04020.02
7.0.20.0200.06720.22
7.0.10.0270.06020.34
7.0.00.0000.05720.17
5.6.210.0070.05320.46
5.6.200.0130.07018.11
5.6.190.0030.04320.42
5.6.180.0270.06720.43
5.6.170.0200.04020.31
5.6.160.0030.04020.50
5.6.150.0000.04018.19
5.6.140.0030.04718.23
5.6.130.0100.06318.14
5.6.120.0100.08021.11
5.6.110.0000.07720.86
5.6.100.0030.09020.97
5.6.90.0030.07720.98
5.6.80.0070.04020.51
5.6.70.0100.07320.37
5.5.350.0330.07320.44
5.5.340.0130.07317.89
5.5.330.0100.08320.36
5.5.320.0030.07720.29
5.5.310.0430.06320.23
5.5.300.0030.04017.98
5.5.290.0030.08717.98
5.5.280.0130.06020.80
5.5.270.0030.07020.86
5.5.260.0030.05020.87
5.5.250.0030.06720.70
5.5.240.0000.04020.28
5.4.450.0030.04019.25
5.4.440.0170.07319.41
5.4.430.0070.07319.11
5.4.420.0100.05319.47
5.4.410.0030.04319.35
5.4.400.0100.06719.21
5.4.390.0070.07718.81
5.4.380.0070.08018.92
5.4.370.0000.05319.17
5.4.360.0130.03018.93
5.4.350.0100.07719.17
5.4.340.0130.07318.81
5.4.320.0100.03318.82
5.4.310.0130.06319.15
5.4.300.0100.07319.14
5.4.290.0130.06719.13
5.4.280.0100.06719.15
5.4.270.0070.08018.77
5.4.260.0130.06719.18
5.4.250.0230.04018.78
5.4.240.0030.03719.11
5.4.230.0070.04019.07
5.4.220.0070.03319.07
5.4.210.0000.04018.80
5.4.200.0000.04019.14
5.4.190.0070.03319.13
5.4.180.0030.03718.80
5.4.170.0030.03718.78
5.4.160.0030.03719.15
5.4.150.0030.04718.77
5.4.140.0030.03716.33
5.4.130.0000.03716.19
5.4.120.0030.04316.35
5.4.110.0030.03316.32
5.4.100.0070.03016.37
5.4.90.0030.03316.60
5.4.80.0070.03016.59
5.4.70.0000.03716.38
5.4.60.0030.03316.26
5.4.50.0000.03716.32
5.4.40.0100.03016.30
5.4.30.0000.03716.26
5.4.20.0000.03716.31
5.4.10.0000.03716.34
5.4.00.0030.03315.79
5.3.290.0000.04314.59
5.3.280.0070.03314.57
5.3.270.0100.05714.53
5.3.260.0070.03314.54
5.3.250.0000.03714.69
5.3.240.0030.03714.54
5.3.230.0070.03314.53
5.3.220.0070.03014.50
5.3.210.0000.04314.50
5.3.200.0030.03714.36
5.3.190.0000.04014.51
5.3.180.0030.03714.49
5.3.170.0070.03014.49
5.3.160.0000.03714.49
5.3.150.0100.03014.54
5.3.140.0030.04014.64
5.3.130.0030.04314.47
5.3.120.0030.03714.48
5.3.110.0030.03714.47
5.3.100.0000.04014.01
5.3.90.0070.03013.94
5.3.80.0030.03313.98
5.3.70.0070.03013.95
5.3.60.0000.03713.79
5.3.50.0070.03313.89
5.3.40.0000.05713.89
5.3.30.0030.04013.85
5.3.20.0070.05313.62
5.3.10.0100.07313.61
5.3.00.0030.06313.56
5.2.170.0070.03311.04
5.2.160.0030.03711.03
5.2.150.0070.03011.04
5.2.140.0000.07011.12
5.2.130.0030.03310.99
5.2.120.0070.04710.96
5.2.110.0000.06311.09
5.2.100.0030.04710.93
5.2.90.0070.05711.08
5.2.80.0070.05011.08
5.2.70.0030.04011.10
5.2.60.0000.04011.01
5.2.50.0030.03010.84
5.2.40.0000.03010.81
5.2.30.0000.04310.96
5.2.20.0030.04710.77
5.2.10.0030.05710.85
5.2.00.0030.05710.71
5.1.60.0030.0439.89
5.1.50.0030.0309.91
5.1.40.0030.0279.98
5.1.30.0070.04710.34
5.1.20.0000.05710.50
5.1.10.0000.03710.11
5.1.00.0130.04710.08
5.0.50.0030.0478.52
5.0.40.0030.0338.39
5.0.30.0030.0478.13
5.0.20.0000.0278.19
5.0.10.0000.0478.16
5.0.00.0030.0608.18
4.4.90.0030.0307.71
4.4.80.0000.0177.71
4.4.70.0000.0277.71
4.4.60.0070.0307.71
4.4.50.0030.0337.71
4.4.40.0030.0577.71
4.4.30.0030.0307.71
4.4.20.0000.0407.71
4.4.10.0030.0337.71
4.4.00.0100.0377.71
4.3.110.0030.0277.71
4.3.100.0000.0307.71
4.3.90.0070.0337.71
4.3.80.0030.0537.71
4.3.70.0000.0237.71
4.3.60.0000.0377.71
4.3.50.0000.0277.71
4.3.40.0030.0237.71
4.3.30.0030.0137.71
4.3.20.0070.0337.71
4.3.10.0030.0277.71
4.3.00.0000.0307.71

preferences:
44.15 ms | 401 KiB | 5 Q