3v4l.org

run code in 300+ PHP versions simultaneously
<?php $HTTP_USER_AGENT = "afeaetest2asdf"; //$_SERVER['HTTP_USER_AGENT'] $INSTALLED_STYLES = array("desktop","mobile",""); //fetch_style_title_options_array() $TOPIFY_SEO_STYLE = "topifySeo"; $seo_agents = "test1,test2,test3"; $custom1agents = str_replace(",","|",$seo_agents);//explode(",",$seo_agents); //echo $custom1agents; if(in_array($TOPIFY_SEO_STYLE, $INSTALLED_STYLES)) { if(preg_match('/('.$custom1agents.')/i', $HTTP_USER_AGENT, $match)) { echo "matched"; } else { echo "did not match"; } } else { echo "topify seo not installed"; }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 15, Position 2 = 27
Branch analysis from position: 15
2 jumps found. (Code = 43) Position 1 = 23, Position 2 = 25
Branch analysis from position: 23
1 jumps found. (Code = 42) Position 1 = 26
Branch analysis from position: 26
1 jumps found. (Code = 42) Position 1 = 28
Branch analysis from position: 28
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 25
1 jumps found. (Code = 42) Position 1 = 28
Branch analysis from position: 28
Branch analysis from position: 27
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/dthJO
function name:  (null)
number of ops:  29
compiled vars:  !0 = $HTTP_USER_AGENT, !1 = $INSTALLED_STYLES, !2 = $TOPIFY_SEO_STYLE, !3 = $seo_agents, !4 = $custom1agents, !5 = $match
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 'afeaetest2asdf'
    3     1        ASSIGN                                                   !1, <array>
    4     2        ASSIGN                                                   !2, 'topifySeo'
    7     3        ASSIGN                                                   !3, 'test1%2Ctest2%2Ctest3'
    8     4        INIT_FCALL                                               'str_replace'
          5        SEND_VAL                                                 '%2C'
          6        SEND_VAL                                                 '%7C'
          7        SEND_VAR                                                 !3
          8        DO_ICALL                                         $10     
          9        ASSIGN                                                   !4, $10
   11    10        INIT_FCALL                                               'in_array'
         11        SEND_VAR                                                 !2
         12        SEND_VAR                                                 !1
         13        DO_ICALL                                         $12     
         14      > JMPZ                                                     $12, ->27
   13    15    >   INIT_FCALL                                               'preg_match'
         16        CONCAT                                           ~13     '%2F%28', !4
         17        CONCAT                                           ~14     ~13, '%29%2Fi'
         18        SEND_VAL                                                 ~14
         19        SEND_VAR                                                 !0
         20        SEND_REF                                                 !5
         21        DO_ICALL                                         $15     
         22      > JMPZ                                                     $15, ->25
   15    23    >   ECHO                                                     'matched'
         24      > JMP                                                      ->26
   19    25    >   ECHO                                                     'did+not+match'
         26    > > JMP                                                      ->28
   24    27    >   ECHO                                                     'topify+seo+not+installed'
   25    28    > > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
168.32 ms | 1388 KiB | 19 Q