3v4l.org

run code in 300+ PHP versions simultaneously
<?php function tidyHTML($buffer) { // load our document into a DOM object $dom = new DOMDocument(); // we want nice output $dom->preserveWhiteSpace = false; $dom->loadHTML($buffer); $dom->formatOutput = true; return($dom->saveHTML()); } echo tidyHTML(' <!DOCTYPE html> <html class="nojs"> <head> <title> Bitly. The power of the link. </title> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <meta content="IE=edge" http-equiv="X-UA-Compatible"> <meta name="keywords" content="bitly, awesome, save, share, shorten" /> <meta name="description" content="Bitly. The power of the link." /> <meta name="viewport" content="width=device-width,minimum-scale=1.0, maximum-scale=1.0, user-scalable=no"> <script type="text/javascript"> // remove nojs from html try{ document.getElementsByTagName("html")[0].className = ""; } catch (ex) { } </script> <link href="//d1ayxb9ooonjts.cloudfront.net/8445e417ef5a6402f5ddd26caa4e1da5.css" rel="stylesheet" type="text/css"> <link href="//d3h5jhobc20ump.cloudfront.net/2e907b3335b17d64aea95955710c394d.css" rel="stylesheet" type="text/css"> <!--[if lte IE 8]> <link href="//d3h5jhobc20ump.cloudfront.net/f521cb9cec0171e8d913538552d98b10.css" rel="stylesheet" type="text/css"> <![endif]--> <link rel="icon" type="image/png" href="//d1ayxb9ooonjts.cloudfront.net/22f1d0b2154c2f58baf06f92038d262a.png" /> <!--[if lte IE 8]> <script src="//dl6fh5ptkejqa.cloudfront.net/1b67aa02ef18dd3ce7e428f8c18a339a.js" type="text/javascript"></script> <![endif]--> </head> <body class="hamburger signed-out-homepage logged-out"> <div class="ext_bitly_chrome_promo_delay promo"> </div> <div id="main"> <div id="sidebar"> <div class="nav"> <ul> <li class="has-right-bullet"><a href="/pages/about">About</a></li> <li class="has-right-bullet"><a href="http://dev.bitly.com">API</a></li> <li><a href="/a/support">Help</a></li> <li class="has-right-bullet"><a href="/a/support" class="uservoice-feedback-link">Contact</a></li> <li><a href="http://blog.bitly.com">Company Blog</a></li> <li><a href="http://word.bitly.com">Engineering Blog</a></li> <li><a href="/pages/jobs">Jobs <span class="callout-label">Hiring!</span></a></li> </ul> <div class="nav-separator"></div> <div class="ext-nav"> <ul class="social-media ext"> <li><a href="//facebook.com/bitly"><i class="fa fa-facebook-square footer-fb"></i></a></li> <li><a href="//twitter.com/bitly"><i class="fa fa-twitter-square footer-tw"></i></a></li> </ul> <a href="/a/mobile" class="mobile_promo"><i class="fa fa-apple"></i> iPhone</a> </div> </div> </div> <div id="container" class="clearfix"> <div class="shorten-wrapper"> <div class="shorten-wrapper-content superwide"> <img id="logo" class="show-large-only logo-header" alt="bitly" src="//d1ayxb9ooonjts.cloudfront.net/b71e37605e0fa7d8535bdaff63770c20.png"> <div id="form_plus_copy_container"> <div id="form_container"><form method="POST" action="/shorten/" name="shortenUrl" id="unAuthShortenForm"> <fieldset class="cf"> <i class="fa fa-fw fa-chain inset-shorten hamburger-hide"></i> <input id="shorten_url" taborder="1" name="url" type="text" class="text" placeholder="Paste a link to shorten it" value="" autocomplete="off" autocorrect="off" autocapitalize="off" /> <input id="shorten_btn" type="submit" class="btn blue-btn square" value="Shorten" /> <input type="hidden" name="basic_style" value="1"> <input type="hidden" name="classic_mode" value=""> <!-- allow rapid shorten --> <input type="hidden" name="rapid_shorten_mode" value=""> <form action="" method="get"> <input type="hidden" name="_xsrf" value="9b32a7b07c52473c94f2e843980bd397"/> </form> </fieldset> </form></div> <span class="show-large-only external_susi sign-up-header"> <strong>Take control of your links,</strong> <a href="/a/sign_up">sign up for free.</a> </span> <span id="signup-links" class="show-large-only external_susi sign-in-header"> <a href="/a/sign_in">Sign in</a> </span> </div> </div> </div> <div class="promo-container"> <div id="signup-links" class="show-small-only external_susi"> <img id="logo" alt="bitly" class="show-small-only promo-center" src="//d1ayxb9ooonjts.cloudfront.net/b71e37605e0fa7d8535bdaff63770c20.png"> <br/> <strong>Take control of your links,</strong><br/> <a href="/a/sign_up">sign up for free.</a> <br/> <a href="/a/sign_in">Sign in</a> </div> <div class="promo-tile devices"> <div class="maintain-aspect mt20"> <img class="promo-image max-all" src="//d1ayxb9ooonjts.cloudfront.net/e3883311785abbe4bfbe185fa5b13a7c.png"> </div> </div> <div class="promo-tile promo-tile--enterprise tile-l"> <h1 class="title_orange">Bitly Brand Tools</h1> <p class="tagline"> <strong>Bitly Brand Tools</strong> are the must-have for marketers to fuel branding, engagement, and understanding in the connected world. </p> <a class="btn square secondary" href="/a/features"> Learn More </a> <div class="headroom text-large"> Trying to shorten a link? <a href="/a/sign_up" class="title_orange">Click here.</a></div> </div> </div> </div> <div id="fw-container" class="c2 clearfix"> <div id="container" class="clearfix c2"> <div class="promo-tile tile-r" id="media-map"> <div class="maintain-aspect mv20"> <h1 class="title_orange mmf">The Bitly Real-Time Media Map</h1> <div alt="rt" class="mm-pin"></div> <p class="tagline"> See who is consuming what media<br/>where in the United States, in real-time! </p> <a class="btn square secondary" href="/a/media_map"> View Now </a> </div> </div> </div> <div id="bottom"> <form action="" method="get"> <input type="hidden" name="_xsrf" value="9b32a7b07c52473c94f2e843980bd397"/> </form> </div> </div> </div> <div id="our-clients" class="clear"> <h1 class="title_black">Our Clients</h1> <p class="tagline"> Sometimes it\'s better to let our clients do the talking. </p> <div id="testimonials"> <img class="testimonial_logo" src="//dl6fh5ptkejqa.cloudfront.net/dfef6f3701605ebbb40097ff6fc270a8.png"> <div id="testimonial1"> <p class="testimonial_logo"> "My favorite thing about Bitly is how I can track our performance with literally one click." <br/> <span class="testimonial_source"> -Liz Kennedy, Social Media Manager, iVillage</span> </p> </div> </div> </div> <div id="footer"> <img class="clients-image" src="//d3h5jhobc20ump.cloudfront.net/db898a50bb145d2b3b8cf42d894da2a2.png"> <div class="large-headroom large-footroom"><a href="http://bitly.com/getstartedform" class="button square secondary lg-button">Get Started</a></div> <div class="footer-link-wrapper text-center"> <ul id="footer_links" class="clearfix"> <li><a href="/a/support">Help</a></li> <li><a href="/a/support" class="uservoice-feedback-link">Contact</a></li> <li><a href="http://dev.bitly.com/">Developers</a></li> <li><a href="/pages/jobs">Jobs</a></li> <li><a href="/pages/about">About</a></li> <li><a href="http://blog.bitly.com/">Blog</a></li> </ul> <p class="copyright">&copy; 2014 Bitly&trade; &middot; handmade in NYC</p> <div class="signedout-homepage social-media"> <span><a href="//facebook.com/bitly"><i class="fa fa-facebook-square footer-fb"></i></a></span> <span><a href="//twitter.com/bitly"><i class="fa fa-twitter-square footer-tw"></i></a></span> <span><a href="//linkedin.com/company/552285?trk=tyah"><i class="fa fa-linkedin-square footer-linkedin"></i></a></span> <span><a href="//plus.google.com/110480996269032856302"><i class="fa fa-google-plus-square footer-google-plus"></i></a></span> </div> </div> </div> <script type="text/javascript" src="//ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js"></script> </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.60.0130.00617.09
8.3.50.0110.00622.22
8.3.40.0120.00319.40
8.3.30.0070.00719.71
8.3.20.0000.01120.84
8.3.10.0040.00424.02
8.3.00.0090.00021.14
8.2.180.0080.00819.29
8.2.170.0070.01122.96
8.2.160.0070.00720.69
8.2.150.0050.00324.18
8.2.140.0060.00324.66
8.2.130.0120.00326.16
8.2.120.0090.00022.52
8.2.110.0000.00922.75
8.2.100.0050.00818.09
8.2.90.0070.00419.59
8.2.80.0030.00618.13
8.2.70.0060.00317.88
8.2.60.0080.00018.54
8.2.50.0060.00318.07
8.2.40.0000.00920.35
8.2.30.0040.00418.52
8.2.20.0040.00417.94
8.2.10.0050.00318.25
8.2.00.0030.00617.86
8.1.280.0090.00925.92
8.1.270.0080.00824.25
8.1.260.0050.00326.35
8.1.250.0040.00428.09
8.1.240.0030.00724.22
8.1.230.0040.00819.66
8.1.220.0030.00618.18
8.1.210.0080.00018.77
8.1.200.0000.00917.85
8.1.190.0030.00617.60
8.1.180.0000.01218.10
8.1.170.0040.00419.02
8.1.160.0040.00422.45
8.1.150.0000.00918.92
8.1.140.0030.00517.92
8.1.130.0030.00618.30
8.1.120.0030.00517.85
8.1.110.0030.00517.82
8.1.100.0040.00417.78
8.1.90.0030.00517.83
8.1.80.0000.00817.78
8.1.70.0060.00317.69
8.1.60.0000.00917.99
8.1.50.0040.00417.91
8.1.40.0040.00717.93
8.1.30.0060.00318.01
8.1.20.0040.00417.93
8.1.10.0060.00317.94
8.1.00.0030.00517.88
8.0.300.0030.00618.77
8.0.290.0060.00317.68
8.0.280.0060.00319.03
8.0.270.0000.00817.54
8.0.260.0000.00717.77
8.0.250.0040.00417.32
8.0.240.0000.01117.36
8.0.230.0000.00817.40
8.0.220.0040.00417.31
8.0.210.0000.00717.30
8.0.200.0030.00317.25
8.0.190.0090.00017.24
8.0.180.0030.00617.20
8.0.170.0060.00317.29
8.0.160.0000.00817.29
8.0.150.0030.00717.29
8.0.140.0040.00417.15
8.0.130.0030.00313.68
8.0.120.0030.00617.22
8.0.110.0050.00317.29
8.0.100.0030.00617.25
8.0.90.0020.00517.27
8.0.80.0070.01417.39
8.0.70.0080.00017.21
8.0.60.0000.00817.18
8.0.50.0030.00517.33
8.0.30.0080.01317.51
8.0.20.0130.01117.69
8.0.10.0060.00317.38
8.0.00.0050.01817.07
7.4.330.0030.00215.00
7.4.320.0000.00717.00
7.4.300.0000.00716.94
7.4.290.0050.00516.90
7.4.280.0000.00716.89
7.4.270.0030.00616.97
7.4.260.0050.00516.85
7.4.250.0000.00816.86
7.4.240.0040.00416.86
7.4.230.0000.00916.71
7.4.220.0070.01117.09
7.4.210.0080.00716.86
7.4.200.0040.00416.95
7.4.190.0030.00517.09
7.4.160.0060.01216.93
7.4.150.0130.00817.40
7.4.140.0080.01117.86
7.4.130.0110.00816.82
7.4.120.0120.00616.96
7.4.110.0090.00916.72
7.4.100.0160.00616.77
7.4.90.0110.00716.76
7.4.80.0150.00919.39
7.4.70.0160.00917.14
7.4.60.0140.01016.76
7.4.50.0000.00616.64
7.4.40.0070.01116.52
7.4.30.0090.00916.84
7.4.00.0090.00915.14
7.3.330.0070.00013.60
7.3.320.0000.00613.58
7.3.310.0000.00816.68
7.3.300.0000.00816.64
7.3.290.0090.00616.57
7.3.280.0090.00816.62
7.3.270.0090.00917.40
7.3.260.0100.01616.77
7.3.250.0090.01016.86
7.3.240.0140.00517.05
7.3.230.0100.01316.63
7.3.210.0090.01216.66
7.3.200.0060.01319.39
7.3.190.0090.01516.91
7.3.180.0030.01416.71
7.3.170.0070.01016.85
7.3.160.0100.00716.68
7.3.120.0060.01115.06
7.3.110.0100.01015.01
7.3.100.0120.00514.97
7.3.90.0060.01114.82
7.3.80.0090.00715.18
7.3.70.0070.00714.86
7.3.60.0050.01214.99
7.3.50.0020.01215.11
7.3.40.0040.00914.89
7.3.30.0030.01314.85
7.3.20.0080.00816.68
7.3.10.0060.01116.68
7.3.00.0070.00616.63
7.2.330.0060.01216.75
7.2.320.0130.00716.83
7.2.310.0130.01017.17
7.2.300.0150.00316.90
7.2.290.0060.01416.77
7.2.250.0060.01415.23
7.2.240.0090.00915.13
7.2.230.0020.01514.93
7.2.220.0120.00715.32
7.2.210.0050.01215.12
7.2.200.0060.00815.02
7.2.190.0070.00915.06
7.2.180.0050.01015.10
7.2.170.0050.00815.05
7.2.160.0040.01115.04
7.2.150.0070.00717.09
7.2.140.0000.01016.97
7.2.130.0070.00717.21
7.2.120.0070.01016.83
7.2.110.0060.00616.96
7.2.100.0000.01216.99
7.2.90.0070.01316.89
7.2.80.0100.00617.07
7.2.70.0030.01317.18
7.2.60.0050.00916.90
7.2.50.0070.00717.08
7.2.40.0040.00717.14
7.2.30.0080.00816.95
7.2.20.0070.01116.93
7.2.10.0070.00716.89
7.2.00.0000.01117.09
7.1.330.0100.00515.89
7.1.320.0030.00816.01
7.1.310.0110.00215.95
7.1.300.0050.01115.83
7.1.290.0030.00815.77
7.1.280.0070.00815.98
7.1.270.0080.00815.98
7.1.260.0050.00715.72
7.1.250.0030.01015.72
7.1.240.0050.00516.00
7.1.230.0030.01015.83
7.1.220.0080.00315.63
7.1.210.0100.00615.83
7.1.200.0070.00816.05
7.1.190.0040.00716.05
7.1.180.0040.01115.86
7.1.170.0100.00715.74
7.1.160.0070.00715.91
7.1.150.0030.00715.86
7.1.140.0070.01015.91
7.1.130.0090.00615.99
7.1.120.0050.00515.62
7.1.110.0110.00416.06
7.1.100.0030.00616.13
7.1.90.0090.00915.77
7.1.80.0040.01115.89
7.1.70.0000.01116.52
7.1.60.0100.01117.69
7.1.50.0060.01316.49
7.1.40.0060.00915.96
7.1.30.0070.01016.04
7.1.20.0080.00816.04
7.1.10.0000.01415.70
7.1.00.0050.04219.17
7.0.330.0040.00715.75
7.0.320.0040.00715.28
7.0.310.0030.01415.66
7.0.300.0060.00315.50
7.0.290.0000.01015.27
7.0.280.0070.00315.38
7.0.270.0040.01115.59
7.0.260.0030.01015.57
7.0.250.0000.00915.27
7.0.240.0030.00615.39
7.0.230.0030.00915.65
7.0.220.0110.00415.46
7.0.210.0080.00815.50
7.0.200.0020.00916.30
7.0.190.0060.00915.60
7.0.180.0090.00615.63
7.0.170.0100.00715.63
7.0.160.0000.01115.37
7.0.150.0000.01215.69
7.0.140.0020.04318.88
7.0.130.0030.01615.26
7.0.120.0100.01015.41
7.0.110.0090.00615.65
7.0.100.0200.02917.71
7.0.90.0220.03917.84
7.0.80.0150.04417.73
7.0.70.0200.03017.78
7.0.60.0250.02517.92
7.0.50.0160.03118.05
7.0.40.0170.02717.02
7.0.30.0020.04816.85
7.0.20.0120.03916.84
7.0.10.0080.03317.01
7.0.00.0080.04916.95
5.6.400.0060.00914.43
5.6.390.0030.01214.41
5.6.380.0040.01114.37
5.6.370.0070.00714.39
5.6.360.0030.01214.64
5.6.350.0000.01014.61
5.6.340.0070.00314.48
5.6.330.0040.00714.88
5.6.320.0030.00914.62
5.6.310.0000.01214.35
5.6.300.0030.00714.41
5.6.290.0120.00314.57
5.6.280.0120.00314.67
5.6.270.0000.01814.70
5.6.260.0100.00714.46
5.6.250.0050.03317.64
5.6.240.0060.04317.63
5.6.230.0150.04017.75
5.6.220.0100.04217.62
5.6.210.0090.04517.68
5.6.200.0060.02317.90
5.6.190.0110.04117.93
5.6.180.0020.04717.96
5.6.170.0070.04717.80
5.6.160.0050.04717.89
5.6.150.0080.05017.75
5.6.140.0120.04017.98
5.6.130.0080.03617.87
5.6.120.0030.04518.00
5.6.110.0100.02717.96
5.6.100.0070.04717.73
5.6.90.0070.03317.98
5.6.80.0050.04717.56
5.6.70.0070.04617.54
5.6.60.0080.03817.49
5.6.50.0100.04317.65
5.6.40.0050.04717.56
5.6.30.0050.02917.54
5.6.20.0080.04317.68
5.6.10.0130.03517.45
5.6.00.0020.04517.49
5.5.380.0120.02217.34
5.5.370.0050.03217.66
5.5.360.0090.04517.65
5.5.350.0070.04517.47
5.5.340.0030.04817.65
5.5.330.0120.04317.83
5.5.320.0080.04217.85
5.5.310.0080.04117.89
5.5.300.0070.02917.75
5.5.290.0050.04817.69
5.5.280.0100.04317.84
5.5.270.0100.02517.79
5.5.260.0040.03917.79
5.5.250.0070.03617.57
5.5.240.0080.04317.53
5.5.230.0080.04217.29
5.5.220.0060.04317.30
5.5.210.0090.03917.49
5.5.200.0080.04317.18
5.5.190.0080.02717.23
5.5.180.0080.04317.44
5.5.170.0060.00614.58
5.5.160.0030.04817.19
5.5.150.0070.03917.42
5.5.140.0030.02817.25
5.5.130.0070.02417.38
5.5.120.0050.03817.38
5.5.110.0050.02717.53
5.5.100.0050.03817.46
5.5.90.0050.04417.30
5.5.80.0100.03817.26
5.5.70.0070.04317.39
5.5.60.0050.04417.40
5.5.50.0050.03617.36
5.5.40.0030.04417.27
5.5.30.0100.03917.25
5.5.20.0070.04017.38
5.5.10.0100.03817.25
5.5.00.0070.02817.40
5.4.450.0020.03215.58
5.4.440.0080.03815.46
5.4.430.0070.03515.46
5.4.420.0070.04215.45
5.4.410.0080.02715.47
5.4.400.0050.03515.14
5.4.390.0070.04015.14
5.4.380.0080.03515.34
5.4.370.0140.03215.29
5.4.360.0040.02515.20
5.4.350.0030.04715.24
5.4.340.0070.04015.28
5.4.330.0050.00311.14
5.4.320.0070.03515.24
5.4.310.0080.03015.19
5.4.300.0030.04515.32
5.4.290.0110.03615.19
5.4.280.0030.03615.26
5.4.270.0060.03515.38
5.4.260.0030.03715.33
5.4.250.0030.03215.09
5.4.240.0050.04215.22
5.4.230.0100.03315.32
5.4.220.0010.04415.30
5.4.210.0020.04815.38
5.4.200.0070.03815.29
5.4.190.0050.04115.04
5.4.180.0060.04315.13
5.4.170.0050.03015.23
5.4.160.0080.04014.99
5.4.150.0080.03715.21
5.4.140.0060.04313.81
5.4.130.0100.03513.96
5.4.120.0000.04413.93
5.4.110.0050.04213.83
5.4.100.0020.04213.92
5.4.90.0030.03813.95
5.4.80.0070.04714.07
5.4.70.0030.04513.84
5.4.60.0070.02413.97
5.4.50.0050.04013.95
5.4.40.0040.04214.05
5.4.30.0030.04113.88
5.4.20.0070.03213.84
5.4.10.0020.03813.85
5.4.00.0050.03513.51
5.3.290.0060.03612.96
5.3.280.0050.04212.82
5.3.270.0060.04312.89
5.3.260.0060.04112.82
5.3.250.0070.03812.88
5.3.240.0060.04412.81
5.3.230.0080.04012.82
5.3.220.0050.04312.84
5.3.210.0050.03712.75
5.3.200.0050.02712.85
5.3.190.0000.04712.79
5.3.180.0070.03812.88
5.3.170.0030.03012.76
5.3.160.0050.02612.79
5.3.150.0050.04212.76
5.3.140.0070.04512.90
5.3.130.0030.04412.85
5.3.120.0030.04412.80
5.3.110.0070.02512.87
5.3.100.0030.04412.50
5.3.90.0050.02512.55
5.3.80.0050.04112.59
5.3.70.0030.02812.60
5.3.60.0050.04012.61
5.3.50.0080.03712.41
5.3.40.0070.04012.58
5.3.30.0050.04012.49
5.3.20.0050.03412.42
5.3.10.0030.04112.31
5.3.00.0020.04212.30
5.2.170.0030.04312.23
5.2.160.0030.05712.23
5.2.150.0030.03012.23
5.2.140.0030.03712.23
5.2.130.0030.05712.23
5.2.120.0100.04312.23
5.2.110.0070.05312.23
5.2.100.0070.06012.23
5.2.90.0030.06012.23
5.2.80.0130.05312.23
5.2.70.0070.04012.23
5.2.60.0070.06012.23
5.2.50.0030.06012.23
5.2.40.0030.04312.23
5.2.30.0070.06312.23
5.2.20.0000.06312.23
5.2.10.0030.03312.23
5.2.00.0070.05712.23
5.1.60.0030.05312.23
5.1.50.0100.06012.23
5.1.40.0100.04712.23
5.1.30.0030.04012.23
5.1.20.0030.04012.23
5.1.10.0070.03312.23
5.1.00.0170.04312.23
5.0.50.0030.04712.23
5.0.40.0030.03312.23
5.0.30.0000.06712.23
5.0.20.0030.04312.23
5.0.10.0000.05012.23
5.0.00.0000.06312.23
4.4.90.0030.03312.23
4.4.80.0030.03712.23
4.4.70.0000.03312.23
4.4.60.0030.03712.23
4.4.50.0030.03312.23
4.4.40.0000.04012.23
4.4.30.0170.01012.23
4.4.20.0070.03012.23
4.4.10.0030.02312.23
4.4.00.0030.05312.23
4.3.110.0030.02712.23
4.3.100.0030.03712.23
4.3.90.0000.03312.23
4.3.80.0000.05312.23
4.3.70.0000.02312.23
4.3.60.0030.03012.23
4.3.50.0000.03712.23
4.3.40.0100.04712.23
4.3.30.0030.03312.23
4.3.20.0000.03712.23
4.3.10.0000.04012.23
4.3.00.0000.02012.23

preferences:
49.86 ms | 401 KiB | 5 Q