3v4l.org

run code in 300+ PHP versions simultaneously
<?php $body = '<div class="cModule myphotos"> <h3><span>My photos</span></h3> <ul class="cResetList cThumbList clrfix"> <li> <a href="/projects/mysportsjam/index.php/joom-social/103-shine/photos/photo?albumid=12#photoid=67" hidefocus="true" style="outline: none;"><img class="cAvatar jomNameTips cAvatar-sidebar" title="Uploaded by shine s" src="http://107.20.167.165/projects/mysportsjam/images/photos/103/12/thumb_05c0beeb8f0f32a08538dad7.jpg" alt="shine s"></a> </li> <li> <a href="/projects/mysportsjam/index.php/joom-social/103-shine/photos/photo?albumid=12#photoid=43" hidefocus="true" style="outline: none;"><img class="cAvatar jomNameTips cAvatar-sidebar" src="http://107.20.167.165/projects/mysportsjam/images/photos/103/12/thumb_c122ff8dafd2edeba377a1cd.jpg" alt="shine s" original-title="Uploaded by shine s"></a> </li> <li> <a href="/projects/mysportsjam/index.php/joom-social/103-shine/photos/photo?albumid=12#photoid=66" hidefocus="true" style="outline: none;"><img class="cAvatar jomNameTips cAvatar-sidebar" title="Uploaded by shine s" src="http://107.20.167.165/projects/mysportsjam/images/photos/103/12/thumb_9414b5dff6c8644d197ff684.jpg" alt="shine s"></a> </li> </ul> <div class="app-box-footer"> <a href="/projects/mysportsjam/index.php/joom-social/103-shine/photos" hidefocus="true" style="outline: none;">View all photos</a> </div> </div>'; $xml = new DOMDocument(); $xml->loadHTML($body); $nodes = $xml->getElementsByTagName('li'); for($curr = 0; $curr < $nodes->length; $curr++) { $li = $nodes->item($curr); $innerHTML= ''; $children = $li->childNodes; foreach ($children as $child) { $innerHTML .= $child->ownerDocument->saveXML( $child ); } print $innerHTML; foreach($li->childNodes as $child) { $a = $child; if(is_a($a, "DOMElement")) { $href = $a->getAttribute('href'); print "{$href}\n"; } } print "\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.40.0110.00419.09
8.3.30.0070.00719.29
8.3.20.0040.00420.41
8.3.10.0040.00422.39
8.3.00.0040.00422.46
8.2.170.0070.01422.96
8.2.160.0140.00021.31
8.2.150.0080.00024.18
8.2.140.0080.00024.66
8.2.130.0070.00026.16
8.2.120.0050.00319.61
8.2.110.0100.00021.32
8.2.100.0060.00618.09
8.2.90.0000.00819.42
8.2.80.0090.00018.00
8.2.70.0050.00317.75
8.2.60.0080.00018.30
8.2.50.0060.00618.07
8.2.40.0000.00918.44
8.2.30.0080.00018.47
8.2.20.0030.00518.00
8.2.10.0040.00419.73
8.2.00.0040.00418.11
8.1.270.0130.00322.59
8.1.260.0120.00326.35
8.1.250.0030.00628.09
8.1.240.0050.00522.56
8.1.230.0120.00019.39
8.1.220.0000.00818.16
8.1.210.0030.00618.77
8.1.200.0040.00417.73
8.1.190.0050.00317.60
8.1.180.0040.00418.10
8.1.170.0050.00319.08
8.1.160.0030.00522.32
8.1.150.0040.00418.86
8.1.140.0040.00417.65
8.1.130.0050.00318.22
8.1.120.0040.00417.69
8.1.110.0040.00417.72
8.1.100.0040.00417.69
8.1.90.0060.00317.65
8.1.80.0040.00417.73
8.1.70.0000.00817.71
8.1.60.0030.00617.90
8.1.50.0040.00417.82
8.1.40.0030.00517.85
8.1.30.0040.00417.96
8.1.20.0060.00317.87
8.1.10.0040.00417.81
8.1.00.0000.00817.82
8.0.300.0000.00820.29
8.0.290.0000.00716.88
8.0.280.0040.00418.68
8.0.270.0040.00417.50
8.0.260.0030.00317.10
8.0.250.0000.00717.27
8.0.240.0000.00717.28
8.0.230.0030.00417.15
8.0.220.0000.00717.18
8.0.210.0030.00317.14
8.0.200.0070.00017.27
8.0.190.0050.00317.27
8.0.180.0030.00517.25
8.0.170.0040.00417.21
8.0.160.0040.00417.13
8.0.150.0000.00817.04
8.0.140.0080.00017.03
8.0.130.0060.00013.59
8.0.120.0030.00617.21
8.0.110.0040.00417.06
8.0.100.0030.00617.11
8.0.90.0000.00717.21
8.0.80.0060.00917.15
8.0.70.0040.00417.12
8.0.60.0000.00817.12
8.0.50.0040.00416.91
8.0.30.0140.00517.10
8.0.20.0100.00917.49
8.0.10.0000.00817.22
8.0.00.0090.01017.06
7.4.330.0030.00315.00
7.4.320.0030.00316.87
7.4.300.0000.00716.71
7.4.290.0000.00716.91
7.4.280.0040.00416.92
7.4.270.0040.00716.84
7.4.260.0040.00417.00
7.4.250.0030.00516.83
7.4.240.0060.00216.87
7.4.230.0070.00016.56
7.4.220.0030.01316.79
7.4.210.0110.00416.82
7.4.200.0000.00716.80
7.4.190.0070.00017.02
7.4.160.0070.01016.77
7.4.150.0110.00617.40
7.4.140.0160.00617.86
7.4.130.0100.01016.63
7.4.120.0070.01116.85
7.4.110.0030.01316.72
7.4.100.0140.00316.50
7.4.90.0080.01116.75
7.4.80.0100.01319.39
7.4.70.0080.01216.63
7.4.60.0100.00716.70
7.4.50.0040.00416.85
7.4.40.0000.01222.77
7.4.30.0120.00316.79
7.4.10.0050.01415.78
7.4.00.0080.00815.39
7.3.330.0040.00213.49
7.3.320.0030.00313.50
7.3.310.0000.00716.63
7.3.300.0070.00016.44
7.3.290.0070.01016.68
7.3.280.0060.01116.60
7.3.270.0040.01217.40
7.3.260.0120.00616.72
7.3.250.0090.01016.74
7.3.240.0090.01116.99
7.3.230.0130.00316.67
7.3.210.0030.01516.75
7.3.200.0150.00516.89
7.3.190.0100.01316.71
7.3.180.0100.00616.75
7.3.170.0100.00716.88
7.3.160.0150.00716.76
7.3.130.0050.01215.82
7.3.120.0060.01115.28
7.3.110.0110.00815.58
7.3.100.0080.00915.41
7.3.90.0090.00515.42
7.3.80.0060.00715.61
7.3.70.0090.00415.60
7.3.60.0120.00315.41
7.3.50.0080.00715.49
7.3.40.0070.00715.45
7.3.30.0040.01015.45
7.3.20.0060.00617.43
7.3.10.0050.01017.29
7.3.00.0040.00617.29
7.2.330.0120.00817.09
7.2.320.0150.01016.86
7.2.310.0030.01316.96
7.2.300.0100.00917.05
7.2.290.0110.00817.07
7.2.260.0130.00815.76
7.2.250.0070.01315.66
7.2.240.0080.00515.85
7.2.230.0060.01015.85
7.2.220.0080.00915.62
7.2.210.0080.00515.85
7.2.200.0110.00515.75
7.2.190.0070.00815.78
7.2.180.0060.00615.81
7.2.170.0040.01315.76
7.2.160.0050.01016.00
7.2.150.0090.00718.03
7.2.140.0080.00917.89
7.2.130.0050.00917.89
7.2.120.0050.01017.92
7.2.110.0020.01118.01
7.2.100.0080.00717.82
7.2.90.0070.00717.74
7.2.80.0070.00817.95
7.2.70.0050.00917.93
7.2.60.0060.00917.88
7.2.50.0050.00617.71
7.2.40.0030.01117.91
7.2.30.0060.00717.93
7.2.20.0040.01017.64
7.2.10.0080.00517.81
7.2.00.0050.00818.31
7.1.330.0050.01016.46
7.1.320.0070.00916.44
7.1.310.0050.00916.43
7.1.300.0020.01316.35
7.1.290.0040.00816.50
7.1.280.0050.00816.35
7.1.270.0050.00816.34
7.1.260.0000.01416.49
7.1.250.0080.00416.77
7.1.240.0030.00816.85
7.1.230.0080.00816.78
7.1.220.0070.00316.72
7.1.210.0070.00616.75
7.1.200.0070.00716.39
7.1.190.0090.00516.79
7.1.180.0050.00816.75
7.1.170.0050.00816.70
7.1.160.0060.00916.66
7.1.150.0060.00716.81
7.1.140.0070.00716.78
7.1.130.0000.01116.78
7.1.120.0070.00716.68
7.1.110.0080.00816.75
7.1.100.0020.00917.23
7.1.90.0050.00716.88
7.1.80.0040.00916.76
7.1.70.0050.00616.81
7.1.60.0060.01017.86
7.1.50.0100.00716.83
7.1.40.0110.00516.70
7.1.30.0120.00316.68
7.1.20.0070.00716.92
7.1.10.0040.00816.68
7.1.00.0070.02818.71
7.0.330.0030.00916.48
7.0.320.0020.01316.39
7.0.310.0080.00516.40
7.0.300.0060.00616.39
7.0.290.0080.00516.57
7.0.280.0050.01016.29
7.0.270.0060.00716.19
7.0.260.0060.01116.46
7.0.250.0050.01016.44
7.0.240.0030.00816.36
7.0.230.0080.00416.37
7.0.220.0060.00816.36
7.0.210.0080.00716.39
7.0.200.0100.00516.54
7.0.190.0090.00516.48
7.0.180.0070.00516.41
7.0.170.0050.01016.37
7.0.160.0070.00516.40
7.0.150.0020.01116.37
7.0.140.0060.02818.35
7.0.130.0080.00516.41
7.0.120.0100.00516.35
7.0.110.0040.00616.43
7.0.100.0070.02817.59
7.0.90.0100.03017.62
7.0.80.0090.02917.48
7.0.70.0020.02517.71
7.0.60.0090.03017.67
7.0.50.0080.02117.74
7.0.40.0060.03616.38
7.0.30.0070.02716.38
7.0.20.0120.02616.29
7.0.10.0050.02116.26
7.0.00.0090.03116.36
5.6.400.0080.00715.37
5.6.390.0050.00715.48
5.6.380.0050.00715.46
5.6.370.0090.00115.29
5.6.360.0060.00415.47
5.6.350.0090.00315.25
5.6.340.0050.00915.33
5.6.330.0050.00715.15
5.6.320.0030.00615.19
5.6.310.0050.00815.66
5.6.300.0040.01015.37
5.6.290.0050.01115.41
5.6.280.0100.02617.17
5.6.270.0060.00815.26
5.6.260.0050.00615.24
5.6.250.0050.02817.18
5.6.240.0100.02817.16
5.6.230.0020.03817.08
5.6.220.0080.02017.20
5.6.210.0030.02317.05
5.6.200.0080.02917.23
5.6.190.0110.03017.32
5.6.180.0100.02917.31
5.6.170.0040.03117.17
5.6.160.0060.02417.19
5.6.150.0060.03217.34
5.6.140.0080.02017.49
5.6.130.0040.02617.43
5.6.120.0080.03217.30
5.6.110.0060.03217.26
5.6.100.0070.02817.34
5.6.90.0070.02917.27
5.6.80.0070.03417.06
5.6.70.0070.03417.06
5.6.60.0060.02216.96
5.6.50.0060.03316.98
5.6.40.0080.03317.01
5.6.30.0080.01816.91
5.6.20.0010.02317.10
5.6.10.0050.02717.02
5.6.00.0060.02216.98
5.5.380.0070.03217.08
5.5.370.0090.03116.96
5.5.360.0080.02916.83
5.5.350.0070.03317.05
5.5.340.0070.02916.98
5.5.330.0030.03217.17
5.5.320.0130.02517.06
5.5.310.0100.03017.23
5.5.300.0090.02417.10
5.5.290.0060.03017.12
5.5.280.0110.02917.03
5.5.270.0090.02017.19
5.5.260.0110.02617.20
5.5.250.0070.02917.00
5.5.240.0100.03016.98
5.5.230.0100.03116.93
5.5.220.0140.02716.85
5.5.210.0130.02516.91
5.5.200.0030.03116.92
5.5.190.0120.02716.95
5.5.180.0060.02916.99
5.5.170.0090.00915.27
5.5.160.0080.03216.85
5.5.150.0060.03316.88
5.5.140.0050.02916.88
5.5.130.0060.01916.70
5.5.120.0060.03216.83
5.5.110.0060.03416.80
5.5.100.0070.02516.80
5.5.90.0080.01916.87
5.5.80.0050.02916.92
5.5.70.0060.03116.81
5.5.60.0050.03116.86
5.5.50.0050.03316.77
5.5.40.0030.03416.83
5.5.30.0060.02916.78
5.5.20.0060.02516.81
5.5.10.0060.02216.90
5.5.00.0120.02716.92
5.4.450.0110.02614.43
5.4.440.0090.02814.20
5.4.430.0050.02914.52
5.4.420.0030.03314.35
5.4.410.0060.02514.40
5.4.400.0080.03014.22
5.4.390.0090.02914.31
5.4.380.0090.02714.14
5.4.370.0050.02314.30
5.4.360.0070.02714.22
5.4.350.0050.03114.30
5.4.340.0030.03514.37
5.4.330.0040.00911.82
5.4.320.0060.02814.27
5.4.310.0050.03114.38
5.4.300.0090.02114.31
5.4.290.0070.01814.35
5.4.280.0090.02414.43
5.4.270.0090.01814.22
5.4.260.0050.03114.23
5.4.250.0030.02814.34
5.4.240.0040.03114.03
5.4.230.0060.02314.38
5.4.220.0030.03214.32
5.4.210.0080.02514.46
5.4.200.0060.02514.29
5.4.190.0060.02814.39
5.4.180.0080.02814.29
5.4.170.0100.02714.42
5.4.160.0070.01714.22
5.4.150.0030.03114.42
5.4.140.0050.01713.59
5.4.130.0030.03013.43
5.4.120.0050.03013.46
5.4.110.0070.02813.42
5.4.100.0040.03113.44
5.4.90.0050.02313.46
5.4.80.0060.02913.40
5.4.70.0050.02813.47
5.4.60.0090.02413.49
5.4.50.0090.02413.60
5.4.40.0030.02013.48
5.4.30.0080.02613.35
5.4.20.0020.03113.43
5.4.10.0050.02913.40
5.4.00.0070.02813.22
5.3.290.0060.02712.83
5.3.280.0040.03112.87
5.3.270.0040.03312.78
5.3.260.0030.02812.78
5.3.250.0030.03012.77
5.3.240.0070.02512.78
5.3.230.0090.02712.88
5.3.220.0070.02612.70
5.3.210.0060.02412.86
5.3.200.0040.02212.85
5.3.190.0090.02512.72
5.3.180.0050.02612.85
5.3.170.0070.02812.97
5.3.160.0050.02012.86
5.3.150.0070.02812.92
5.3.140.0070.02812.82
5.3.130.0060.03012.86
5.3.120.0040.03112.80
5.3.110.0060.02712.79
5.3.100.0080.02612.64
5.3.90.0030.03212.61
5.3.80.0050.03112.59
5.3.70.0070.02812.59
5.3.60.0060.03112.55
5.3.50.0060.02812.42
5.3.40.0070.01712.52
5.3.30.0050.03312.55
5.3.20.0050.02212.52
5.3.10.0040.02812.25
5.3.00.0090.01912.31
5.2.170.0000.06311.30
5.2.160.0100.05711.25
5.2.150.0070.05311.16
5.2.140.0070.02711.26
5.2.130.0030.06711.11
5.2.120.0070.06011.13
5.2.110.0070.06311.11
5.2.100.0030.06011.02
5.2.90.0130.05311.26
5.2.80.0070.03311.11
5.2.70.0070.06011.29
5.2.60.0070.06011.13
5.2.50.0000.06711.18
5.2.40.0000.05311.08
5.2.30.0070.05711.12
5.2.20.0030.04011.04
5.2.10.0130.05010.98
5.2.00.0100.05710.80
5.1.60.0030.05310.15
5.1.50.0130.04710.15
5.1.40.0100.04710.11
5.1.30.0030.05710.33
5.1.20.0070.05310.55
5.1.10.0070.05710.10
5.1.00.0000.06010.13
5.0.50.0030.0478.68
5.0.40.0030.0378.50
5.0.30.0030.0608.26
5.0.20.0030.0408.26
5.0.10.0000.0478.33
5.0.00.0100.0608.34
4.4.90.0030.0208.03
4.4.80.0030.0308.03
4.4.70.0030.0378.03
4.4.60.0000.0208.03
4.4.50.0070.0308.03
4.4.40.0030.0508.03
4.4.30.0030.0308.03
4.4.20.0000.0338.03
4.4.10.0070.0308.03
4.4.00.0000.0578.03
4.3.110.0070.0308.03
4.3.100.0070.0308.03
4.3.90.0030.0338.03
4.3.80.0030.0538.03
4.3.70.0100.0278.03
4.3.60.0070.0308.03
4.3.50.0030.0308.03
4.3.40.0030.0378.03
4.3.30.0000.0378.03
4.3.20.0030.0378.03
4.3.10.0000.0378.03
4.3.00.0030.0308.03

preferences:
40.54 ms | 400 KiB | 5 Q