3v4l.org

run code in 300+ PHP versions simultaneously
<?php $imageTag = '<img src = http://nycxplorer.com/wp-content/uploads/2012/02/bagel1-1.jpg >'; //grab the src portion of the image tag $srcPattern = "/src.*?=.*?(\s|>)/s"; preg_match($srcPattern, $imageTag, $srcParts); $srcPart = $srcParts[0]; //remove all whitespace from within and around the src portion $srcPart = trim(preg_replace('/[\s]+/','', $srcPart)); print_r($srcpart); //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); ?>

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.01118.46
8.3.50.0110.00522.12
8.3.40.0080.00819.01
8.3.30.0070.00719.06
8.3.20.0080.00020.52
8.3.10.0040.00422.11
8.3.00.0080.00022.57
8.2.180.0090.00917.00
8.2.170.0120.00322.96
8.2.160.0040.01120.97
8.2.150.0030.00524.18
8.2.140.0090.00024.66
8.2.130.0070.00026.16
8.2.120.0040.00419.73
8.2.110.0030.00722.20
8.2.100.0130.00019.87
8.2.90.0040.00419.29
8.2.80.0080.00018.03
8.2.70.0090.00017.88
8.2.60.0060.00318.05
8.2.50.0080.00018.07
8.2.40.0040.00718.34
8.2.30.0000.00818.19
8.2.20.0080.00017.86
8.2.10.0000.00717.89
8.2.00.0040.00418.09
8.1.280.0120.00625.92
8.1.270.0040.00423.96
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0080.00023.96
8.1.230.0000.01219.14
8.1.220.0080.00017.78
8.1.210.0080.00018.77
8.1.200.0060.00317.50
8.1.190.0040.00417.40
8.1.180.0030.00518.10
8.1.170.0050.00318.64
8.1.160.0070.00022.05
8.1.150.0000.00718.79
8.1.140.0050.00217.60
8.1.130.0000.00817.82
8.1.120.0030.00517.63
8.1.110.0050.00317.61
8.1.100.0000.00717.53
8.1.90.0000.00717.64
8.1.80.0070.00017.61
8.1.70.0030.00317.55
8.1.60.0030.00617.64
8.1.50.0050.00317.68
8.1.40.0000.00817.59
8.1.30.0050.00317.66
8.1.20.0000.00817.85
8.1.10.0000.00817.68
8.1.00.0000.00817.72
8.0.300.0030.00518.77
8.0.290.0070.00017.18
8.0.280.0070.00018.52
8.0.270.0000.00717.33
8.0.260.0000.00617.08
8.0.250.0070.00017.13
8.0.240.0040.00417.08
8.0.230.0070.00017.21
8.0.220.0040.00417.16
8.0.210.0070.00017.09
8.0.200.0030.00317.17
8.0.190.0000.00717.21
8.0.180.0040.00417.17
8.0.170.0060.00317.13
8.0.160.0000.00717.18
8.0.150.0000.00817.09
8.0.140.0040.00417.05
8.0.130.0030.00313.46
8.0.120.0040.00416.96
8.0.110.0080.00017.09
8.0.100.0000.00717.14
8.0.90.0070.00017.14
8.0.80.0060.01617.04
8.0.70.0040.00417.11
8.0.60.0000.00716.96
8.0.50.0040.00417.09
8.0.30.0080.01117.18
8.0.20.0110.00817.40
8.0.10.0040.00417.27
8.0.00.0150.00716.99
7.4.330.0050.00015.00
7.4.320.0030.00316.80
7.4.300.0080.00016.80
7.4.290.0000.00716.90
7.4.280.0050.00316.71
7.4.270.0070.00016.67
7.4.260.0070.00016.79
7.4.250.0000.00816.71
7.4.240.0050.00216.74
7.4.230.0040.00416.61
7.4.220.0090.01016.79
7.4.210.0090.00916.76
7.4.200.0000.00716.80
7.4.190.0040.00416.81
7.4.160.0080.00816.80
7.4.150.0070.01017.40
7.4.140.0090.01017.86
7.4.130.0090.00816.77
7.4.120.0120.00916.86
7.4.110.0070.01116.62
7.4.100.0130.00716.80
7.4.90.0100.00716.63
7.4.80.0070.01016.78
7.4.70.0100.00716.66
7.4.60.0100.00616.73
7.4.50.0040.00416.88
7.4.40.0090.00622.77
7.4.30.0070.01016.52
7.4.00.0020.01314.97
7.3.330.0000.00513.31
7.3.320.0030.00313.39
7.3.310.0050.00316.38
7.3.300.0070.00016.42
7.3.290.0100.00316.49
7.3.280.0110.00516.51
7.3.270.0090.00917.40
7.3.260.0160.00016.52
7.3.250.0070.01316.56
7.3.240.0070.01516.47
7.3.230.0070.01016.65
7.3.210.0100.01316.57
7.3.200.0120.01219.39
7.3.190.0060.01116.50
7.3.180.0080.00816.54
7.3.170.0070.01416.75
7.3.160.0090.00916.76
7.3.120.0050.01115.13
7.3.110.0040.00814.84
7.3.100.0070.00714.84
7.3.90.0030.00715.13
7.3.80.0060.00314.96
7.3.70.0050.00514.88
7.3.60.0000.01414.89
7.3.50.0090.00315.10
7.3.40.0110.00314.81
7.3.30.0030.01714.78
7.3.20.0100.00317.02
7.3.10.0060.01317.03
7.3.00.0000.01416.96
7.2.330.0180.00016.75
7.2.320.0120.00616.71
7.2.310.0150.00716.79
7.2.300.0100.00616.93
7.2.290.0000.01616.95
7.2.250.0000.01915.28
7.2.240.0070.01015.18
7.2.230.0090.00015.24
7.2.220.0120.00315.28
7.2.210.0090.00615.04
7.2.200.0030.01515.38
7.2.190.0070.00314.93
7.2.180.0100.00715.27
7.2.170.0040.00715.16
7.2.60.0100.00717.15
7.2.00.0030.01019.63
7.1.330.0030.01015.66
7.1.320.0030.00715.90
7.1.310.0080.00616.14
7.1.300.0090.00615.93
7.1.290.0130.00315.88
7.1.280.0030.01016.05
7.1.270.0070.01015.80
7.1.260.0030.01216.07
7.1.200.0000.01115.98
7.1.100.0060.00618.31
7.1.70.0040.00417.50
7.1.60.0090.00619.82
7.1.50.0120.00917.16
7.1.00.0030.07322.30
7.0.200.0030.00516.96
7.0.140.0070.07021.92
7.0.60.0070.07720.01
7.0.50.0100.07317.89
7.0.40.0070.08320.09
7.0.30.0200.04720.20
7.0.20.0330.03020.01
7.0.10.0070.08720.20
7.0.00.0200.06720.18
5.6.210.0100.05720.44
5.6.200.0030.08318.11
5.6.190.0130.03320.45
5.6.180.0270.04020.33
5.6.170.0170.05020.38
5.6.160.0000.04320.50
5.6.150.0100.05718.15
5.6.140.0030.06018.20
5.6.130.0000.06718.15
5.6.120.0070.05321.01
5.6.110.0070.08721.13
5.6.100.0030.08721.02
5.6.90.0130.06321.09
5.6.80.0130.06020.43
5.5.350.4270.03720.33
5.5.340.0030.05017.92
5.5.330.0000.05720.37
5.5.320.0600.06720.51
5.5.310.0230.07720.34
5.5.300.0000.04318.02
5.5.290.0130.03317.91
5.5.280.0130.04720.97
5.5.270.0030.08320.95
5.5.260.0000.04720.86
5.5.250.0070.07020.61
5.5.240.0170.07720.02
5.4.450.3470.04319.41
5.4.440.3170.04019.56
5.4.430.3730.03319.40
5.4.420.3670.04019.23
5.4.410.3200.04019.28
5.4.400.3670.04719.08
5.4.390.3270.03718.80
5.4.380.3400.03719.09
5.4.370.3370.03719.08
5.4.360.3700.04718.81
5.4.350.3770.03319.06
5.4.340.3300.03319.23
5.4.320.3470.03719.18
5.4.310.3600.03318.92
5.4.300.3200.04019.21
5.4.290.3400.04019.13
5.4.280.3500.04019.20
5.4.270.3670.04719.08
5.4.260.0070.04319.09
5.4.250.0400.03318.92
5.4.240.3300.03719.03
5.4.230.3770.03319.07
5.4.220.3330.03719.18
5.4.210.3530.03719.07
5.4.200.3700.03719.09
5.4.190.3500.04018.78
5.4.180.3330.03719.08
5.4.170.3870.03318.79
5.4.160.4200.03319.06
5.4.150.4200.04019.21
5.4.140.3100.03316.36
5.4.130.3830.03716.28
5.4.120.2730.03016.45
5.4.110.2770.03716.42
5.4.100.2800.04016.38
5.4.90.3070.02716.49
5.4.80.2100.03316.19
5.4.70.2970.03016.37
5.4.60.2500.03316.22
5.4.50.3400.03316.17
5.4.40.3570.03016.31
5.4.30.3500.03316.27
5.4.20.3400.03716.16
5.4.10.3700.04016.38
5.4.00.3500.03315.68
5.3.290.3330.04314.61
5.3.280.3300.03314.46
5.3.270.3570.04314.46
5.3.260.4200.04314.70
5.3.250.3670.04014.46
5.3.240.3230.03714.58
5.3.230.3400.04014.57
5.3.220.2830.04014.40
5.3.210.2170.03314.57
5.3.200.2000.03014.52
5.3.190.2930.03714.41
5.3.180.3930.01714.39
5.3.170.2400.03014.42
5.3.160.3070.03314.39
5.3.150.3600.04014.65
5.3.140.3730.04314.43
5.3.130.2570.03314.63
5.3.120.3370.04014.50
5.3.110.3570.04014.40
5.3.100.3600.04013.88
5.3.90.3530.03313.88
5.3.80.3270.03013.82
5.3.70.3470.04014.08
5.3.60.3870.03313.98
5.3.50.3900.03313.89
5.3.40.3500.03313.89
5.3.30.3700.04013.75
5.3.20.3530.04013.67
5.3.10.3670.03713.51
5.3.00.3070.03713.50
5.2.170.2970.03011.20
5.2.160.2800.02311.04
5.2.150.3530.02311.20
5.2.140.3000.03311.00
5.2.130.3600.02311.20
5.2.120.3130.03011.25
5.2.110.2970.02710.94
5.2.100.3200.02311.12
5.2.90.2800.03010.99
5.2.80.3130.03011.14
5.2.70.2930.03310.93
5.2.60.2770.03310.97
5.2.50.3170.03011.06
5.2.40.3030.02010.85
5.2.30.2330.03010.82
5.2.20.2070.02310.89
5.2.10.2630.03010.78
5.2.00.2570.03310.80
5.1.60.2300.0239.96
5.1.50.2900.0239.90
5.1.40.2600.0209.85
5.1.30.2630.02710.25
5.1.20.2570.02710.25
5.1.10.2300.02710.04
5.1.00.2630.02310.16
5.0.50.1570.0209.69
5.0.40.1330.0239.69
5.0.30.1370.0379.69
5.0.20.1230.0209.69
5.0.10.1100.0209.69
5.0.00.1330.0339.69
4.4.90.1330.0109.69
4.4.80.1430.0139.69
4.4.70.1470.0109.69
4.4.60.1300.0209.69
4.4.50.1470.0179.69
4.4.40.1230.0209.69
4.4.30.1600.0139.69
4.4.20.1630.0179.69
4.4.10.1300.0179.69
4.4.00.1370.0239.69
4.3.110.1200.0179.69
4.3.100.0730.0209.69
4.3.90.1000.0179.69
4.3.80.1130.0209.69
4.3.70.1430.0179.69
4.3.60.1430.0179.69
4.3.50.1270.0139.69
4.3.40.1030.0279.69
4.3.30.0600.0139.69
4.3.20.0730.0239.69
4.3.10.0600.0209.69
4.3.00.0670.0239.69

preferences:
41.32 ms | 401 KiB | 5 Q