3v4l.org

run code in 300+ PHP versions simultaneously
<?php $body = '<blockquote class="twitter-tweet" data-lang="ja"><p lang="en" dir="ltr">Thank you ! ~ that is all :) <a href="https://t.co/4evflUT84g">pic.twitter.com/4evflUT84g</a></p>— Chicago Police (@Chicago_Police) <a href="https://twitter.cm/Chicago_Police/status/877727536125419520">2017年6月22日</a></blockquote><script async="" src="//platform.twitter.com/widgets.js" charset="utf-8"></script>'; $body = preg_replace_callback('!(<blockquote class="twitter-tweet" data-lang="ja">.*?</blockquote>.+?twitter.com.+?<\/script>)!s', function ($matches) { var_dump($matches); return '[[embed-twitter]](' . trim($matches[2]) . ')'; }, $body); echo $body; ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/6Vf6c
function name:  (null)
number of ops:  10
compiled vars:  !0 = $body
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, '%3Cblockquote+class%3D%22twitter-tweet%22+data-lang%3D%22ja%22%3E%3Cp+lang%3D%22en%22+dir%3D%22ltr%22%3EThank+you+%21+%7E+that+is+all+%3A%29+%3Ca+href%3D%22https%3A%2F%2Ft.co%2F4evflUT84g%22%3Epic.twitter.com%2F4evflUT84g%3C%2Fa%3E%3C%2Fp%3E%E2%80%94+Chicago+Police+%28%40Chicago_Police%29+%3Ca+href%3D%22https%3A%2F%2Ftwitter.cm%2FChicago_Police%2Fstatus%2F877727536125419520%22%3E2017%E5%B9%B46%E6%9C%8822%E6%97%A5%3C%2Fa%3E%3C%2Fblockquote%3E%3Cscript+async%3D%22%22+src%3D%22%2F%2Fplatform.twitter.com%2Fwidgets.js%22+charset%3D%22utf-8%22%3E%3C%2Fscript%3E'
    4     1        INIT_FCALL                                               'preg_replace_callback'
          2        SEND_VAL                                                 '%21%28%3Cblockquote+class%3D%22twitter-tweet%22+data-lang%3D%22ja%22%3E.%2A%3F%3C%2Fblockquote%3E.%2B%3Ftwitter.com.%2B%3F%3C%5C%2Fscript%3E%29%21s'
          3        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2F6Vf6c%3A4%240'
    7     4        SEND_VAL                                                 ~2
          5        SEND_VAR                                                 !0
          6        DO_ICALL                                         $3      
    4     7        ASSIGN                                                   !0, $3
    9     8        ECHO                                                     !0
   11     9      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2F6Vf6c%3A4%240:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/6Vf6c
function name:  {closure}
number of ops:  12
compiled vars:  !0 = $matches
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   RECV                                             !0      
    5     1        INIT_FCALL                                               'var_dump'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                                 
    6     4        INIT_FCALL                                               'trim'
          5        FETCH_DIM_R                                      ~2      !0, 2
          6        SEND_VAL                                                 ~2
          7        DO_ICALL                                         $3      
          8        CONCAT                                           ~4      '%5B%5Bembed-twitter%5D%5D%28', $3
          9        CONCAT                                           ~5      ~4, '%29'
         10      > RETURN                                                   ~5
    7    11*     > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2F6Vf6c%3A4%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
164.7 ms | 941 KiB | 20 Q