3v4l.org

run code in 300+ PHP versions simultaneously
<?php $str = '<!doctype html> <html> <head> <script type="text/javascript">alert(fasdfsd)</script> <meta charset="utf-8"> <script type="text/javascript"> var fasdfsd="fasdfsd"; </script> <script type="text/javascript" src="http://google.adv.js"></script> <title> hey </title> <script> alert("hello"); </script> <script type="text/javascript" src="lfasd.js"></script> </head> <body> hey </body> </html>'; $str = preg_replace("@<script[^>]*?>.*?</script>@siu","",$str); $str = preg_replace("/(\n)*/","\n",$str); echo html_entity_decode($str);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/kDUnW
function name:  (null)
number of ops:  18
compiled vars:  !0 = $str
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, '%3C%21doctype+html%3E%0A%3Chtml%3E%0A++++%3Chead%3E%0A++++++++%3Cscript+type%3D%22text%2Fjavascript%22%3Ealert%28fasdfsd%29%3C%2Fscript%3E%0A++++++++%3Cmeta+charset%3D%22utf-8%22%3E%0A++++++++%3Cscript+type%3D%22text%2Fjavascript%22%3E%0A++++++++var+fasdfsd%3D%22fasdfsd%22%3B%0A++++++++%3C%2Fscript%3E%0A++++++++%3Cscript+type%3D%22text%2Fjavascript%22+src%3D%22http%3A%2F%2Fgoogle.adv.js%22%3E%3C%2Fscript%3E%0A++++++++%3Ctitle%3E%0A++++++++++++hey%0A++++++++%3C%2Ftitle%3E%0A++++++++%3Cscript%3E%0A++++++++++++alert%28%22hello%22%29%3B%0A++++++++%3C%2Fscript%3E%0A++++++++%3Cscript+type%3D%22text%2Fjavascript%22+src%3D%22lfasd.js%22%3E%3C%2Fscript%3E%0A++++%3C%2Fhead%3E%0A++++%3Cbody%3E%0A++++++++hey%0A++++%3C%2Fbody%3E%0A%3C%2Fhtml%3E'
   23     1        INIT_FCALL                                               'preg_replace'
          2        SEND_VAL                                                 '%40%3Cscript%5B%5E%3E%5D%2A%3F%3E.%2A%3F%3C%2Fscript%3E%40siu'
          3        SEND_VAL                                                 ''
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                         $2      
          6        ASSIGN                                                   !0, $2
   24     7        INIT_FCALL                                               'preg_replace'
          8        SEND_VAL                                                 '%2F%28%0A%29%2A%2F'
          9        SEND_VAL                                                 '%0A'
         10        SEND_VAR                                                 !0
         11        DO_ICALL                                         $4      
         12        ASSIGN                                                   !0, $4
   25    13        INIT_FCALL                                               'html_entity_decode'
         14        SEND_VAR                                                 !0
         15        DO_ICALL                                         $6      
         16        ECHO                                                     $6
         17      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.2 ms | 1387 KiB | 17 Q