3v4l.org

run code in 300+ PHP versions simultaneously
<?php $html = '<html><body><div class="item active" style="display: block; left: 685.5753504672897px; top: 0px; height: 475.3125px; width: 318.84929906542055px; font-size: 100%; z-index: 32768; visibility: visible;"></div></body></html>'; $doc = new DOMDocument(); $doc->loadHTML($html); $xpath = new DOMXPath($doc); $resulted = $xpath->query('div[@class="active"]'); foreach ($resulted as $result) { $active = $result->query('div[@class="content"]'); }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 16, Position 2 = 22
Branch analysis from position: 16
2 jumps found. (Code = 78) Position 1 = 17, Position 2 = 22
Branch analysis from position: 17
1 jumps found. (Code = 42) Position 1 = 16
Branch analysis from position: 16
Branch analysis from position: 22
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 22
filename:       /in/Q8uFq
function name:  (null)
number of ops:  24
compiled vars:  !0 = $html, !1 = $doc, !2 = $xpath, !3 = $resulted, !4 = $result, !5 = $active
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '%3Chtml%3E%3Cbody%3E%3Cdiv+class%3D%22item+active%22+style%3D%22display%3A+block%3B+left%3A+685.5753504672897px%3B+top%3A+0px%3B+height%3A+475.3125px%3B+width%3A+318.84929906542055px%3B+font-size%3A+100%25%3B+z-index%3A+32768%3B+visibility%3A+visible%3B%22%3E%3C%2Fdiv%3E%3C%2Fbody%3E%3C%2Fhtml%3E'
    5     1        NEW                                              $7      'DOMDocument'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !1, $7
    6     4        INIT_METHOD_CALL                                         !1, 'loadHTML'
          5        SEND_VAR_EX                                              !0
          6        DO_FCALL                                      0          
    7     7        NEW                                              $11     'DOMXPath'
          8        SEND_VAR_EX                                              !1
          9        DO_FCALL                                      0          
         10        ASSIGN                                                   !2, $11
    8    11        INIT_METHOD_CALL                                         !2, 'query'
         12        SEND_VAL_EX                                              'div%5B%40class%3D%22active%22%5D'
         13        DO_FCALL                                      0  $14     
         14        ASSIGN                                                   !3, $14
    9    15      > FE_RESET_R                                       $16     !3, ->22
         16    > > FE_FETCH_R                                               $16, !4, ->22
   10    17    >   INIT_METHOD_CALL                                         !4, 'query'
         18        SEND_VAL_EX                                              'div%5B%40class%3D%22content%22%5D'
         19        DO_FCALL                                      0  $17     
         20        ASSIGN                                                   !5, $17
    9    21      > JMP                                                      ->16
         22    >   FE_FREE                                                  $16
   11    23      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
149.8 ms | 1395 KiB | 13 Q