3v4l.org

run code in 300+ PHP versions simultaneously
<?php $data = <<<DATA <a href="/video5505298733/travel_and_tourism_recovery_coronavirus." title="The places and companies missing tourist dollars most.">The places and companies missing tourist dollars most.</a></p><p class="info"><span class="bg"><span class="duration">10 min</span><a href="/get/index.php?id=qafMsaaScGLPuKqGuanBpZjHtGHKppeHpJu5r6G9raaHoqa3tJS-ope5tJK6s5TLqp8"><span class="name">CORONAVIRUS</span></a><span><span class="bolder"> - </span> 1.7k <span class="bolder">Views</span></span><span class="text-disabled"><span class="bolder"> - </span> 2 days ago</span><span class="bolder"> - </span></span></p></div></div> <div class="thumb-lock "><div class="thumb-big"><div class="thumb"><a href="/midia54891337/PICSNUM/russia_fire_coronavirus_patients_intl"><img src="lightbox.gif" data-src="https://cdn-pic.cnews-cdn.com/videos/thumbs169/22/d3/a2/22d3a23423dfda7f5/22d3a2dfbb9fdfgd43f5.PICNUM.jpg" /></a> DATA; $dom = new DOMDocument(); @$dom->loadHTML($data); $items = $dom->getElementsByTagName("a"); foreach ($items as $item) { $href = $item->getAttribute("href"); preg_match("~^(?!(?:/get|\S*/PICSNUM))~", $href, $matches); if ($matches) { echo $href; } }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 77) Position 1 = 14, Position 2 = 27
Branch analysis from position: 14
2 jumps found. (Code = 78) Position 1 = 15, Position 2 = 27
Branch analysis from position: 15
2 jumps found. (Code = 43) Position 1 = 25, Position 2 = 26
Branch analysis from position: 25
1 jumps found. (Code = 42) Position 1 = 14
Branch analysis from position: 14
Branch analysis from position: 26
Branch analysis from position: 27
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 27
filename:       /in/tLrtW
function name:  (null)
number of ops:  29
compiled vars:  !0 = $data, !1 = $dom, !2 = $items, !3 = $item, !4 = $href, !5 = $matches
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '%3Ca+href%3D%22%2Fvideo5505298733%2Ftravel_and_tourism_recovery_coronavirus.%22+title%3D%22The+places+and+companies+missing+tourist+dollars+most.%22%3EThe+places+and+companies+missing+tourist+dollars+most.%3C%2Fa%3E%3C%2Fp%3E%3Cp+class%3D%22info%22%3E%3Cspan+class%3D%22bg%22%3E%3Cspan+class%3D%22duration%22%3E10+min%3C%2Fspan%3E%3Ca+href%3D%22%2Fget%2Findex.php%3Fid%3DqafMsaaScGLPuKqGuanBpZjHtGHKppeHpJu5r6G9raaHoqa3tJS-ope5tJK6s5TLqp8%22%3E%3Cspan+class%3D%22name%22%3ECORONAVIRUS%3C%2Fspan%3E%3C%2Fa%3E%3Cspan%3E%3Cspan+class%3D%22bolder%22%3E+-+%3C%2Fspan%3E+1.7k+%3Cspan+class%3D%22bolder%22%3EViews%3C%2Fspan%3E%3C%2Fspan%3E%3Cspan+class%3D%22text-disabled%22%3E%3Cspan+class%3D%22bolder%22%3E+-+%3C%2Fspan%3E+2+days+ago%3C%2Fspan%3E%3Cspan+class%3D%22bolder%22%3E+-+%3C%2Fspan%3E%3C%2Fspan%3E%3C%2Fp%3E%3C%2Fdiv%3E%3C%2Fdiv%3E%09%09%09%09%3Cdiv+class%3D%22thumb-lock+%22%3E%3Cdiv+class%3D%22thumb-big%22%3E%3Cdiv+class%3D%22thumb%22%3E%3Ca+href%3D%22%2Fmidia54891337%2FPICSNUM%2Frussia_fire_coronavirus_patients_intl%22%3E%3Cimg+src%3D%22lightbox.gif%22+data-src%3D%22https%3A%2F%2Fcdn-pic.cnews-cdn.com%2Fvideos%2Fthumbs169%2F22%2Fd3%2Fa2%2F22d3a23423dfda7f5%2F22d3a2dfbb9fdfgd43f5.PICNUM.jpg%22++%2F%3E%3C%2Fa%3E'
    7     1        NEW                                              $7      'DOMDocument'
          2        DO_FCALL                                      0          
          3        ASSIGN                                                   !1, $7
    8     4        BEGIN_SILENCE                                    ~10     
          5        INIT_METHOD_CALL                                         !1, 'loadHTML'
          6        SEND_VAR_EX                                              !0
          7        DO_FCALL                                      0          
          8        END_SILENCE                                              ~10
   10     9        INIT_METHOD_CALL                                         !1, 'getElementsByTagName'
         10        SEND_VAL_EX                                              'a'
         11        DO_FCALL                                      0  $12     
         12        ASSIGN                                                   !2, $12
   11    13      > FE_RESET_R                                       $14     !2, ->27
         14    > > FE_FETCH_R                                               $14, !3, ->27
   12    15    >   INIT_METHOD_CALL                                         !3, 'getAttribute'
         16        SEND_VAL_EX                                              'href'
         17        DO_FCALL                                      0  $15     
         18        ASSIGN                                                   !4, $15
   13    19        INIT_FCALL                                               'preg_match'
         20        SEND_VAL                                                 '%7E%5E%28%3F%21%28%3F%3A%2Fget%7C%5CS%2A%2FPICSNUM%29%29%7E'
         21        SEND_VAR                                                 !4
         22        SEND_REF                                                 !5
         23        DO_ICALL                                                 
   14    24      > JMPZ                                                     !5, ->26
   15    25    >   ECHO                                                     !4
   11    26    > > JMP                                                      ->14
         27    >   FE_FREE                                                  $14
   17    28      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
146.86 ms | 1015 KiB | 14 Q