3v4l.org

run code in 300+ PHP versions simultaneously
<?php $text = "prova %[ciao]%"; $text = preg_replace('/\{([^\} ]+)\}/ime', '%[$1]%', $text); echo "TESTO" . $text;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/iaB7p
function name:  (null)
number of ops:  10
compiled vars:  !0 = $text
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, 'prova+%25%5Bciao%5D%25'
    4     1        INIT_FCALL                                               'preg_replace'
          2        SEND_VAL                                                 '%2F%5C%7B%28%5B%5E%5C%7D+%5D%2B%29%5C%7D%2Fime'
          3        SEND_VAL                                                 '%25%5B%241%5D%25'
          4        SEND_VAR                                                 !0
          5        DO_ICALL                                         $2      
          6        ASSIGN                                                   !0, $2
    6     7        CONCAT                                           ~4      'TESTO', !0
          8        ECHO                                                     ~4
          9      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
173.01 ms | 1394 KiB | 15 Q