3v4l.org

run code in 300+ PHP versions simultaneously
<?php $html=<<<'HTML' <div class="wrapper"> <div class="some_useless_div"> <p>Some useless text paragraph.</p> <div id="another_useless_div"> <p>The actual important part is: SOME_DYNAMIC_TEXT what I want to put into a variable. The text around that dynamic text is static text and will not change.</p> </div> </div> </div> HTML; preg_match('/The actual important part is\: (.*?) what I want to put into a variable\./',$html,$matches); $str=$matches[1]; var_dump($str);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/6YeSh
function name:  (null)
number of ops:  12
compiled vars:  !0 = $html, !1 = $matches, !2 = $str
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, '%3Cdiv+class%3D%22wrapper%22%3E%0A++%3Cdiv+class%3D%22some_useless_div%22%3E%0A++++%3Cp%3ESome+useless+text+paragraph.%3C%2Fp%3E%0A++++%3Cdiv+id%3D%22another_useless_div%22%3E%0A++++++%3Cp%3EThe+actual+important+part+is%3A+SOME_DYNAMIC_TEXT+what+I+want+to+put+into+a+variable.+The+text+around+that+dynamic+text+is+static+text+and+will+not+change.%3C%2Fp%3E%0A++++%3C%2Fdiv%3E%0A++%3C%2Fdiv%3E%0A%3C%2Fdiv%3E'
   12     1        INIT_FCALL                                               'preg_match'
          2        SEND_VAL                                                 '%2FThe+actual+important+part+is%5C%3A+%28.%2A%3F%29+what+I+want+to+put+into+a+variable%5C.%2F'
          3        SEND_VAR                                                 !0
          4        SEND_REF                                                 !1
          5        DO_ICALL                                                 
   13     6        FETCH_DIM_R                                      ~5      !1, 1
          7        ASSIGN                                                   !2, ~5
   14     8        INIT_FCALL                                               'var_dump'
          9        SEND_VAR                                                 !2
         10        DO_ICALL                                                 
         11      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
142.87 ms | 1000 KiB | 15 Q