3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = '<h1>Oude tekst hier</h1>'; $search = "/[^<h1>](.*)[^<\/h1>]/"; $replace = "Here my new text"; $content = preg_replace($search,$replace,$string); echo $content;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/0JBZB
function name:  (null)
number of ops:  11
compiled vars:  !0 = $string, !1 = $search, !2 = $replace, !3 = $content
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '%3Ch1%3EOude+tekst+hier%3C%2Fh1%3E'
    5     1        ASSIGN                                                   !1, '%2F%5B%5E%3Ch1%3E%5D%28.%2A%29%5B%5E%3C%5C%2Fh1%3E%5D%2F'
    6     2        ASSIGN                                                   !2, 'Here+my+new+text'
    8     3        INIT_FCALL                                               'preg_replace'
          4        SEND_VAR                                                 !1
          5        SEND_VAR                                                 !2
          6        SEND_VAR                                                 !0
          7        DO_ICALL                                         $7      
          8        ASSIGN                                                   !3, $7
   10     9        ECHO                                                     !3
   11    10      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
148.15 ms | 1449 KiB | 14 Q