3v4l.org

run code in 300+ PHP versions simultaneously
<?php $varText = "\\teststring\test \/somestring\string/string"; $varText = str_replace("//", '/', str_replace("\\", '/', $varText)); echo $varText;
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/1PLkG
function name:  (null)
number of ops:  14
compiled vars:  !0 = $varText
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, '%5Cteststring%09est++++%5C%2Fsomestring%5Cstring%2Fstring'
    3     1        INIT_FCALL                                               'str_replace'
          2        SEND_VAL                                                 '%2F%2F'
          3        SEND_VAL                                                 '%2F'
          4        INIT_FCALL                                               'str_replace'
          5        SEND_VAL                                                 '%5C'
          6        SEND_VAL                                                 '%2F'
          7        SEND_VAR                                                 !0
          8        DO_ICALL                                         $2      
          9        SEND_VAR                                                 $2
         10        DO_ICALL                                         $3      
         11        ASSIGN                                                   !0, $3
    4    12        ECHO                                                     !0
         13      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
156.62 ms | 1394 KiB | 15 Q