3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = '"res":"https://my.site.com/image/I/fj23l6j2lgk_AM1200_.jpg"'; echo preg_match('~(?<=^"res":")https://my\.site\.com/image/I/[a-zA-z\d]{11}_\w*_\.jpg(?="$)~', $string, $out) ? $out[0] : 'no match';
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 7, Position 2 = 10
Branch analysis from position: 7
1 jumps found. (Code = 42) Position 1 = 11
Branch analysis from position: 11
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 10
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/rM3ga
function name:  (null)
number of ops:  13
compiled vars:  !0 = $string, !1 = $out
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   ASSIGN                                                   !0, '%22res%22%3A%22https%3A%2F%2Fmy.site.com%2Fimage%2FI%2Ffj23l6j2lgk_AM1200_.jpg%22'
    5     1        INIT_FCALL                                               'preg_match'
          2        SEND_VAL                                                 '%7E%28%3F%3C%3D%5E%22res%22%3A%22%29https%3A%2F%2Fmy%5C.site%5C.com%2Fimage%2FI%2F%5Ba-zA-z%5Cd%5D%7B11%7D_%5Cw%2A_%5C.jpg%28%3F%3D%22%24%29%7E'
          3        SEND_VAR                                                 !0
          4        SEND_REF                                                 !1
          5        DO_ICALL                                         $3      
          6      > JMPZ                                                     $3, ->10
          7    >   FETCH_DIM_R                                      ~4      !1, 0
          8        QM_ASSIGN                                        ~5      ~4
          9      > JMP                                                      ->11
         10    >   QM_ASSIGN                                        ~5      'no+match'
         11    >   ECHO                                                     ~5
         12      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
141.35 ms | 943 KiB | 14 Q