3v4l.org

run code in 300+ PHP versions simultaneously
<?php $textarea = '<div class="dotted-highlight">The cover letter should include: <div class="dotted-highlight"><ul>'; $replacing_to = '((<div class="dotted-highlight">)([^<\n]*)\s?).*?\2.*?<ul>'; $replacing_with = '$3<ul>'; $textarea = preg_replace('#'.$replacing_to.'#', $replacing_with, $textarea); var_dump($textarea);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/1iaXT
function name:  (null)
number of ops:  15
compiled vars:  !0 = $textarea, !1 = $replacing_to, !2 = $replacing_with
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, '%3Cdiv+class%3D%22dotted-highlight%22%3EThe+cover+letter+should+include%3A+%0A%3Cdiv+class%3D%22dotted-highlight%22%3E%3Cul%3E'
    4     1        ASSIGN                                                   !1, '%28%28%3Cdiv+class%3D%22dotted-highlight%22%3E%29%28%5B%5E%3C%5Cn%5D%2A%29%5Cs%3F%29.%2A%3F%5C2.%2A%3F%3Cul%3E'
    5     2        ASSIGN                                                   !2, '%243%3Cul%3E'
    6     3        INIT_FCALL                                               'preg_replace'
          4        CONCAT                                           ~6      '%23', !1
          5        CONCAT                                           ~7      ~6, '%23'
          6        SEND_VAL                                                 ~7
          7        SEND_VAR                                                 !2
          8        SEND_VAR                                                 !0
          9        DO_ICALL                                         $8      
         10        ASSIGN                                                   !0, $8
    7    11        INIT_FCALL                                               'var_dump'
         12        SEND_VAR                                                 !0
         13        DO_ICALL                                                 
         14      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
154.49 ms | 1010 KiB | 15 Q