3v4l.org

run code in 300+ PHP versions simultaneously
<?php function strip_html_tags( $text ) { $text = preg_replace( array( // Remove invisible content '@<head[^>]*?>.*?</head>@siu', '@<style[^>]*?>.*?</style>@siu', '@<script[^>]*?.*?</script>@siu', '@<object[^>]*?.*?</object>@siu', '@<embed[^>]*?.*?</embed>@siu', '@<applet[^>]*?.*?</applet>@siu', '@<noframes[^>]*?.*?</noframes>@siu', '@<noscript[^>]*?.*?</noscript>@siu', '@<noembed[^>]*?.*?</noembed>@siu' ), array( '', '', '', '', '', '', '', '', ''), $text ); return strip_tags( $text); } function make_safe($variable) { $variable = strip_html_tags($variable); $bad = array("=","<", ">", "/","\"","`","~","'","$","%","#"); $variable = str_replace($bad, " ", $variable); $variable = (trim($variable)); //$variable = str_replace(' ','',$variable); echo $variable; } make_safe("<p>Test-A bsatz. </p>"); ?>

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.00916.75
8.3.50.0140.00522.36
8.3.40.0090.01318.96
8.3.30.0120.00419.05
8.3.20.0070.00020.13
8.3.10.0050.00323.48
8.3.00.0050.00320.79
8.2.180.0100.01018.54
8.2.170.0070.00722.96
8.2.160.0100.00320.29
8.2.150.0080.00024.18
8.2.140.0040.00424.66
8.2.130.0080.00026.16
8.2.120.0080.00020.35
8.2.110.0000.00822.37
8.2.100.0060.00619.88
8.2.90.0040.00419.35
8.2.80.0000.00817.97
8.2.70.0070.00317.88
8.2.60.0000.00817.93
8.2.50.0000.00918.07
8.2.40.0080.00019.91
8.2.30.0070.00318.23
8.2.20.0060.00318.10
8.2.10.0000.00718.12
8.2.00.0100.00017.96
8.1.280.0170.00325.92
8.1.270.0090.00023.88
8.1.260.0080.00026.35
8.1.250.0070.00028.09
8.1.240.0000.00924.03
8.1.230.0080.00419.01
8.1.220.0050.00317.79
8.1.210.0000.00818.77
8.1.200.0040.00417.24
8.1.190.0000.00817.35
8.1.180.0030.00618.94
8.1.170.0030.00518.71
8.1.160.0080.00022.04
8.1.150.0000.00818.73
8.1.140.0000.00717.60
8.1.130.0050.00217.89
8.1.120.0040.00417.48
8.1.110.0040.00417.52
8.1.100.0070.00017.45
8.1.90.0050.00217.56
8.1.80.0060.00317.46
8.1.70.0070.00017.58
8.1.60.0040.00417.72
8.1.50.0060.00317.64
8.1.40.0090.00317.63
8.1.30.0040.00417.77
8.1.20.0000.00817.86
8.1.10.0000.00717.70
8.1.00.0000.00817.54
8.0.300.0040.00418.77
8.0.290.0040.00417.29
8.0.280.0040.00418.36
8.0.270.0000.00717.30
8.0.260.0030.00317.38
8.0.250.0070.00017.25
8.0.240.0020.00517.05
8.0.230.0050.00317.12
8.0.220.0030.00317.06
8.0.210.0030.00317.01
8.0.200.0000.00717.10
8.0.190.0040.00417.15
8.0.180.0040.00417.05
8.0.170.0080.00017.09
8.0.160.0020.00517.05
8.0.150.0040.00417.08
8.0.140.0000.00717.03
8.0.130.0060.00013.48
8.0.120.0060.00317.00
8.0.110.0040.00417.11
8.0.100.0000.00817.14
8.0.90.0050.00317.03
8.0.80.0060.01617.06
8.0.70.0000.00717.11
8.0.60.0040.00416.95
8.0.50.0000.00817.18
8.0.30.0100.01217.52
8.0.20.0090.00917.41
8.0.10.0040.00417.02
8.0.00.0130.00516.98
7.4.330.0050.00015.15
7.4.320.0060.00016.81
7.4.300.0000.00616.65
7.4.290.0170.00016.82
7.4.280.0030.00616.73
7.4.270.0000.00716.80
7.4.260.0040.00416.89
7.4.250.0020.00516.84
7.4.240.0020.00516.83
7.4.230.0000.00716.70
7.4.220.0090.00916.74
7.4.210.0060.00916.86
7.4.200.0000.00716.79
7.4.190.0030.00316.88
7.4.160.0040.01216.73
7.4.150.0120.00617.40
7.4.140.0110.01017.86
7.4.130.0100.01116.70
7.4.120.0140.00816.67
7.4.110.0090.00916.53
7.4.100.0060.01316.62
7.4.90.0030.01516.70
7.4.80.0040.01519.39
7.4.70.0040.01416.68
7.4.60.0160.00716.68
7.4.50.0050.00016.85
7.4.40.0080.00816.77
7.4.30.0120.00616.69
7.4.00.0060.01015.12
7.3.330.0000.00513.45
7.3.320.0030.00313.47
7.3.310.0030.00316.51
7.3.300.0000.00716.39
7.3.290.0030.01116.52
7.3.280.0060.01316.53
7.3.270.0060.01017.40
7.3.260.0090.00916.76
7.3.250.0090.00916.68
7.3.240.0130.00316.58
7.3.230.0090.00916.77
7.3.210.0180.00016.60
7.3.200.0000.01819.39
7.3.190.0070.01516.86
7.3.180.0100.01016.42
7.3.170.0040.01216.79
7.3.160.0130.00316.54
7.3.120.0030.01115.09
7.3.110.0040.01515.21
7.3.100.0040.01515.03
7.3.90.0110.00715.08
7.3.80.0060.00915.09
7.3.70.0110.00415.05
7.3.60.0000.01014.80
7.3.50.0070.00715.18
7.3.40.0000.01315.12
7.3.30.0040.00415.01
7.3.20.0040.00816.93
7.3.10.0070.00416.73
7.3.00.0070.00716.96
7.2.330.0070.01716.62
7.2.320.0170.00616.53
7.2.310.0110.00616.68
7.2.300.0100.00716.86
7.2.290.0130.01016.86
7.2.250.0110.00815.03
7.2.240.0000.01915.28
7.2.230.0130.00715.16
7.2.220.0140.00715.07
7.2.210.0000.01215.13
7.2.200.0070.01015.20
7.2.190.0040.00715.32
7.2.180.0090.00615.05
7.2.170.0060.00915.21
7.2.00.0070.00719.19
7.1.330.0000.01316.00
7.1.320.0060.00316.03
7.1.310.0060.00916.01
7.1.300.0080.00416.00
7.1.290.0000.01316.04
7.1.280.0070.00716.08
7.1.270.0090.00016.03
7.1.260.0060.00615.98
7.1.100.0040.01118.46
7.1.70.0050.00217.43
7.1.60.0140.01019.46
7.1.50.0160.01217.22
7.1.00.0030.07722.39
7.0.200.0040.00416.82
7.0.140.0070.07021.97
7.0.100.0200.05320.07
7.0.90.0130.07719.90
7.0.80.0130.07720.14
7.0.70.0270.05019.91
7.0.60.0100.04719.96
7.0.50.0300.08320.27
7.0.40.0070.04720.10
7.0.30.0100.04720.18
7.0.20.0200.07319.99
7.0.10.0000.09019.99
7.0.00.0130.07720.14
5.6.280.0070.06721.07
5.6.250.0100.08020.61
5.6.240.0100.08720.69
5.6.230.0100.07720.59
5.6.220.0070.07320.68
5.6.210.0130.07020.63
5.6.200.0030.05721.05
5.6.190.0100.08021.04
5.6.180.0100.06021.02
5.6.170.0100.08720.91
5.6.160.0070.06721.05
5.6.150.0030.04320.94
5.6.140.0100.03721.17
5.6.130.0030.04721.13
5.6.120.0030.04321.04
5.6.110.0000.05020.96
5.6.100.0030.05020.95
5.6.90.0030.03721.16
5.6.80.0070.03320.40
5.6.70.0070.03720.34
5.6.60.0070.03720.33
5.6.50.0070.04020.48
5.6.40.0070.03020.41
5.6.30.0070.08020.38
5.6.20.0030.04020.47
5.6.10.0070.03720.29
5.6.00.0000.04020.41
5.5.380.0030.06720.37
5.5.370.0070.05020.41
5.5.360.0000.08020.42
5.5.350.0130.06720.46
5.5.340.0130.08020.92
5.5.330.0100.05020.84
5.5.320.0070.04320.84
5.5.310.0100.06020.89
5.5.300.0030.04720.78
5.5.290.0130.04320.84
5.5.280.0130.03320.89
5.5.270.0030.04020.81
5.5.260.0130.03720.92
5.5.250.0100.03020.68
5.5.240.0030.04020.23
5.5.230.0100.03320.12
5.5.220.0000.03720.21
5.5.210.0070.05020.26
5.5.200.0130.06720.25
5.5.190.0070.03720.24
5.5.180.0070.03720.12
5.5.160.0070.03720.23
5.5.150.0030.04020.13
5.5.140.0000.04320.25
5.5.130.0030.04020.28
5.5.120.0100.03720.24
5.5.110.0030.04020.21
5.5.100.0100.03320.16
5.5.90.0030.05020.16
5.5.80.0030.04020.16
5.5.70.0030.04019.98
5.5.60.0070.03720.07
5.5.50.0130.03020.16
5.5.40.0070.04320.16
5.5.30.0000.04320.20
5.5.20.0070.03720.06
5.5.10.0070.03720.13
5.5.00.0070.03720.08
5.4.450.0170.03019.51
5.4.440.0030.04719.58
5.4.430.0030.03719.46
5.4.420.0030.04019.44
5.4.410.0030.04019.18
5.4.400.0030.04019.10
5.4.390.0030.05018.97
5.4.380.0200.03018.95
5.4.370.0030.06719.13
5.4.360.0070.07319.03
5.4.350.0100.06719.21
5.4.340.0030.04018.85
5.4.320.0100.04719.18
5.4.310.0030.04019.09
5.4.300.0030.03719.23
5.4.290.0100.03019.20
5.4.280.0000.04019.04
5.4.270.0070.03318.87
5.4.260.0070.03319.09
5.4.250.0070.03719.13
5.4.240.0030.04019.23
5.4.230.0030.04018.94
5.4.220.0030.04319.23
5.4.210.0000.04019.15
5.4.200.0030.03719.04
5.4.190.0000.04019.17
5.4.180.0030.03719.04
5.4.170.0000.04319.04
5.4.160.0100.03319.03
5.4.150.0070.03718.86
5.4.140.0070.03316.50
5.4.130.0000.03716.38
5.4.120.0000.03716.49
5.4.110.0000.04016.52
5.4.100.0030.03716.55
5.4.90.0000.03716.54
5.4.80.0070.07016.50
5.4.70.0100.06716.39
5.4.60.0030.03716.34
5.4.50.0000.07716.40
5.4.40.0100.07016.36
5.4.30.0100.04316.39
5.4.20.0070.05716.36
5.4.10.0070.05316.45
5.4.00.0070.03015.86
5.3.290.0100.03314.73
5.3.280.0030.04014.55
5.3.270.0070.03714.56
5.3.260.0030.05014.57
5.3.250.0070.03014.75
5.3.240.0070.03314.60
5.3.230.0000.03314.66
5.3.220.0000.03314.54
5.3.210.0030.04014.68
5.3.200.0000.04014.52
5.3.190.0100.07014.59
5.3.180.0070.05014.52
5.3.170.0100.04714.50
5.3.160.0170.06014.63
5.3.150.0030.07314.59
5.3.140.0070.07314.58
5.3.130.0000.07714.66
5.3.120.0070.08014.49
5.3.110.0000.04714.48
5.3.100.0070.07314.01
5.3.90.0100.03714.04
5.3.80.0100.07314.02
5.3.70.0070.05014.08
5.3.60.0070.04013.89
5.3.50.0100.07313.89
5.3.40.0130.06314.07
5.3.30.0070.06713.82
5.3.20.0070.07013.79
5.3.10.0070.06313.59
5.3.00.0030.04313.53
5.2.170.0100.05011.75
5.2.160.0000.06311.75
5.2.150.0000.04011.75
5.2.140.0030.05311.75
5.2.130.0030.05011.75
5.2.120.0030.06711.75
5.2.110.0100.05711.75
5.2.100.0100.05011.75
5.2.90.0070.05011.75
5.2.80.0030.06311.75
5.2.70.0100.05711.75
5.2.60.0100.04311.75
5.2.50.0000.04011.75
5.2.40.0070.06011.75
5.2.30.0070.05711.75
5.2.20.0030.04311.75
5.2.10.0000.03711.75
5.2.00.0070.06011.75
5.1.60.0030.03311.75
5.1.50.0000.06011.75
5.1.40.0030.03311.75
5.1.30.0130.04311.75
5.1.20.0030.05311.75
5.1.10.0130.05311.75
5.1.00.0070.03311.75
5.0.50.0130.02311.75
5.0.40.0070.04311.75
5.0.30.0070.06311.75
5.0.20.0000.03711.75
5.0.10.0030.04011.75
5.0.00.0000.03711.75
4.4.90.0030.03711.75
4.4.80.0030.02011.75
4.4.70.0000.02011.75
4.4.60.0030.02311.75
4.4.50.0000.03711.75
4.4.40.0070.04011.75
4.4.30.0070.03311.75
4.4.20.0070.03311.75
4.4.10.0000.03311.75
4.4.00.0000.04711.75
4.3.110.0000.03711.75
4.3.100.0000.02311.75
4.3.90.0030.01311.75
4.3.80.0000.02711.75
4.3.70.0000.01711.75
4.3.60.0000.02711.75
4.3.50.0000.01711.75
4.3.40.0000.05011.75
4.3.30.0000.04011.75
4.3.20.0070.03011.75
4.3.10.0000.03011.75
4.3.00.0000.02711.75

preferences:
46 ms | 400 KiB | 5 Q