3v4l.org

run code in 300+ PHP versions simultaneously
<?php $raw_html = <<<EOF <p> Some text here <strong class="wanna-attributes-too">with strong element!</strong>. But there can be even <b>bold</b> tag and many others. </p> EOF; $dom = new DOMDocument(); $dom->loadHTML($raw_html); $html = simplexml_import_dom($dom); var_dump($dom);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/v9OUj
function name:  (null)
number of ops:  15
compiled vars:  !0 = $raw_html, !1 = $dom, !2 = $html
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '%3Cp%3E%0A++++Some+text+here+%3Cstrong+class%3D%22wanna-attributes-too%22%3Ewith+strong+element%21%3C%2Fstrong%3E.%0A++++But+there+can+be+even+%3Cb%3Ebold%3C%2Fb%3E+tag+and+many+others.%0A%3C%2Fp%3E'
   10     1        NEW                                              $4      'DOMDocument'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !1, $4
   11     4        INIT_METHOD_CALL                                         !1, 'loadHTML'
          5        SEND_VAR_EX                                              !0
          6        DO_FCALL                                      0          
   12     7        INIT_FCALL                                               'simplexml_import_dom'
          8        SEND_VAR                                                 !1
          9        DO_ICALL                                         $8      
         10        ASSIGN                                                   !2, $8
   14    11        INIT_FCALL                                               'var_dump'
         12        SEND_VAR                                                 !1
         13        DO_ICALL                                                 
         14      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
152.73 ms | 1394 KiB | 17 Q