3v4l.org

run code in 500+ PHP versions simultaneously
<?php $html=<<<HTML <!DOCTYPE html> <html lang="en"> <head> <script> function test(a) { for(let n=0; n < a.length; n++){ console.log(a[n]); } }; test(['one', 'two']); </script> </head> <body> <p>content</p> </body> </html> HTML; var_dump(strip_tags($html));
Output for 8.1.0 - 8.1.34, 8.2.0 - 8.2.34, 8.3.0 - 8.3.35, 8.4.1 - 8.4.26, 8.5.0 - 8.5.11
string(133) " function test(a) { for(let n=0; n < a.length; n++){ console.log(a[n]); } }; test(['one', 'two']); content "

preferences:
31.79 ms | 1496 KiB | 7 Q