3v4l.org

run code in 300+ PHP versions simultaneously
<?php $msg = 'grjqgbqgrqg0 38975893240- http://www.gg.pl/afa31f312u34b151j5b1598139189'; $adNr = preg_replace_callback('#http://[^\s]+#', function($ma) { if (substr($ma[0], 0, 17) !== 'http://www.gg.pl/') { return $ma[0]; } }, $msg); echo $adNr;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/dXP87
function name:  (null)
number of ops:  10
compiled vars:  !0 = $msg, !1 = $adNr
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'grjqgbqgrqg0+38975893240-+http%3A%2F%2Fwww.gg.pl%2Fafa31f312u34b151j5b1598139189'
    5     1        INIT_FCALL                                               'preg_replace_callback'
          2        SEND_VAL                                                 '%23http%3A%2F%2F%5B%5E%5Cs%5D%2B%23'
          3        DECLARE_LAMBDA_FUNCTION                                  '%00%7Bclosure%7D%2Fin%2FdXP87%3A5%240'
    9     4        SEND_VAL                                                 ~3
          5        SEND_VAR                                                 !0
          6        DO_ICALL                                         $4      
    5     7        ASSIGN                                                   !1, $4
   12     8        ECHO                                                     !1
          9      > RETURN                                                   1

Function %00%7Bclosure%7D%2Fin%2FdXP87%3A5%240:
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 9, Position 2 = 11
Branch analysis from position: 9
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 11
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/dXP87
function name:  {closure}
number of ops:  12
compiled vars:  !0 = $ma
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    5     0  E >   RECV                                             !0      
    6     1        INIT_FCALL                                               'substr'
          2        FETCH_DIM_R                                      ~1      !0, 0
          3        SEND_VAL                                                 ~1
          4        SEND_VAL                                                 0
          5        SEND_VAL                                                 17
          6        DO_ICALL                                         $2      
          7        IS_NOT_IDENTICAL                                         $2, 'http%3A%2F%2Fwww.gg.pl%2F'
          8      > JMPZ                                                     ~3, ->11
    7     9    >   FETCH_DIM_R                                      ~4      !0, 0
         10      > RETURN                                                   ~4
    9    11    > > RETURN                                                   null

End of function %00%7Bclosure%7D%2Fin%2FdXP87%3A5%240

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
173.29 ms | 1395 KiB | 17 Q