3v4l.org

run code in 300+ PHP versions simultaneously
<?php // main title of product $maintitle = 'CHICKENBUFFET HOT WINGS'; // take first word from $maintitle and put in new variable list($title1) = explode(' ', $maintitle); // words that start with CHICKEN are removed and put in new variable $title2 = preg_replace('/\w+BUFFET/', '', $maintitle); // echo titles echo $title1."\n"; echo trim($title2);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/FbMjk
function name:  (null)
number of ops:  21
compiled vars:  !0 = $maintitle, !1 = $title1, !2 = $title2
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   ASSIGN                                                   !0, 'CHICKENBUFFET+HOT+WINGS'
    7     1        INIT_FCALL                                               'explode'
          2        SEND_VAL                                                 '+'
          3        SEND_VAR                                                 !0
          4        DO_ICALL                                         $4      
          5        FETCH_LIST_R                                     $5      $4, 0
          6        ASSIGN                                                   !1, $5
          7        FREE                                                     $4
   10     8        INIT_FCALL                                               'preg_replace'
          9        SEND_VAL                                                 '%2F%5Cw%2BBUFFET%2F'
         10        SEND_VAL                                                 ''
         11        SEND_VAR                                                 !0
         12        DO_ICALL                                         $7      
         13        ASSIGN                                                   !2, $7
   13    14        CONCAT                                           ~9      !1, '%0A'
         15        ECHO                                                     ~9
   14    16        INIT_FCALL                                               'trim'
         17        SEND_VAR                                                 !2
         18        DO_ICALL                                         $10     
         19        ECHO                                                     $10
         20      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
144.93 ms | 1399 KiB | 19 Q