3v4l.org

run code in 300+ PHP versions simultaneously
<?php //assert($a == $b); // 相等 $i = 0; while ($i < 5) { if ($i === 3) { break; // 退出循环 } echo $i++; } // 输出 "012" for ($i = 0; $i < 5; $i++) { if ($i === 3) { continue; // 跳过此次遍历 } echo $i; } // 输出 "0124" $nowdoc = <<<'END' Multi line string END; echo $nowdoc; die; header('Content-type: text/html; charset=utf-8'); echo '<br />百度关键词URL编码转换示例:<br />'; $urlBaidu = 'http://www.baidu.com/s?wd=%D6%D0%CE%C4'; $arrParse = parse_url($urlBaidu); var_dump($arrParse); parse_str($arrParse ['query'],$output); var_dump($output); echo '乱码:' . $output['wd'] . '<br />'; //将gb2312编码转换成utf-8编码 $strUTF8 = mb_convert_encoding($output['wd'], 'utf-8', 'gb2312'); echo '可读码:' . $strUTF8 . '<br />'; echo '<br />谷歌关键词URL编码转换示例:<br />'; $urlGoogle = 'http://www.google.cn/search?hl=zh-CN&source=hp&q=%E4%B8%AD%E6%96%87&aq=f&oq='; $arrParse = parse_url($urlGoogle); var_dump($arrParse); parse_str($arrParse ['query'],$output); var_dump($output); //谷歌关键词URL编码是utf-8,不用再作转换 echo '可读码:' . $output['q'] . '<br />'; echo $escaped = "This contains a \t tab character."; echo $unescaped = 'This just contains a slash and a t: \t';
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 7
Branch analysis from position: 7
2 jumps found. (Code = 44) Position 1 = 9, Position 2 = 2
Branch analysis from position: 9
1 jumps found. (Code = 42) Position 1 = 16
Branch analysis from position: 16
2 jumps found. (Code = 44) Position 1 = 18, Position 2 = 11
Branch analysis from position: 18
1 jumps found. (Code = 79) Position 1 = -2
Branch analysis from position: 11
2 jumps found. (Code = 43) Position 1 = 13, Position 2 = 14
Branch analysis from position: 13
1 jumps found. (Code = 42) Position 1 = 15
Branch analysis from position: 15
2 jumps found. (Code = 44) Position 1 = 18, Position 2 = 11
Branch analysis from position: 18
Branch analysis from position: 11
Branch analysis from position: 14
2 jumps found. (Code = 44) Position 1 = 18, Position 2 = 11
Branch analysis from position: 18
Branch analysis from position: 11
Branch analysis from position: 2
2 jumps found. (Code = 43) Position 1 = 4, Position 2 = 5
Branch analysis from position: 4
1 jumps found. (Code = 42) Position 1 = 9
Branch analysis from position: 9
Branch analysis from position: 5
2 jumps found. (Code = 44) Position 1 = 9, Position 2 = 2
Branch analysis from position: 9
Branch analysis from position: 2
filename:       /in/lefRG
function name:  (null)
number of ops:  81
compiled vars:  !0 = $i, !1 = $nowdoc, !2 = $urlBaidu, !3 = $arrParse, !4 = $output, !5 = $strUTF8, !6 = $urlGoogle, !7 = $escaped, !8 = $unescaped
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   ASSIGN                                                   !0, 0
    5     1      > JMP                                                      ->7
    6     2    >   IS_IDENTICAL                                             !0, 3
          3      > JMPZ                                                     ~10, ->5
    7     4    > > JMP                                                      ->9
    9     5    >   POST_INC                                         ~11     !0
          6        ECHO                                                     ~11
    5     7    >   IS_SMALLER                                               !0, 5
          8      > JMPNZ                                                    ~12, ->2
   12     9    >   ASSIGN                                                   !0, 0
         10      > JMP                                                      ->16
   13    11    >   IS_IDENTICAL                                             !0, 3
         12      > JMPZ                                                     ~14, ->14
   14    13    > > JMP                                                      ->15
   16    14    >   ECHO                                                     !0
   12    15    >   PRE_INC                                                  !0
         16    >   IS_SMALLER                                               !0, 5
         17      > JMPNZ                                                    ~16, ->11
   18    18    >   ASSIGN                                                   !1, 'Multi+line%0Astring'
   23    19        ECHO                                                     !1
   24    20      > EXIT                                                     
   27    21*       INIT_FCALL                                               'header'
         22*       SEND_VAL                                                 'Content-type%3A+text%2Fhtml%3B+charset%3Dutf-8'
         23*       DO_ICALL                                                 
   29    24*       ECHO                                                     '%3Cbr+%2F%3E%E7%99%BE%E5%BA%A6%E5%85%B3%E9%94%AE%E8%AF%8DURL%E7%BC%96%E7%A0%81%E8%BD%AC%E6%8D%A2%E7%A4%BA%E4%BE%8B%EF%BC%9A%3Cbr+%2F%3E'
   31    25*       ASSIGN                                                   !2, 'http%3A%2F%2Fwww.baidu.com%2Fs%3Fwd%3D%25D6%25D0%25CE%25C4'
   33    26*       INIT_FCALL                                               'parse_url'
         27*       SEND_VAR                                                 !2
         28*       DO_ICALL                                         $20     
         29*       ASSIGN                                                   !3, $20
   34    30*       INIT_FCALL                                               'var_dump'
         31*       SEND_VAR                                                 !3
         32*       DO_ICALL                                                 
   35    33*       INIT_FCALL                                               'parse_str'
         34*       FETCH_DIM_R                                      ~23     !3, 'query'
         35*       SEND_VAL                                                 ~23
         36*       SEND_REF                                                 !4
         37*       DO_ICALL                                                 
   36    38*       INIT_FCALL                                               'var_dump'
         39*       SEND_VAR                                                 !4
         40*       DO_ICALL                                                 
   37    41*       FETCH_DIM_R                                      ~26     !4, 'wd'
         42*       CONCAT                                           ~27     '%E4%B9%B1%E7%A0%81%EF%BC%9A', ~26
         43*       CONCAT                                           ~28     ~27, '%3Cbr+%2F%3E'
         44*       ECHO                                                     ~28
   40    45*       INIT_FCALL                                               'mb_convert_encoding'
         46*       FETCH_DIM_R                                      ~29     !4, 'wd'
         47*       SEND_VAL                                                 ~29
         48*       SEND_VAL                                                 'utf-8'
         49*       SEND_VAL                                                 'gb2312'
         50*       DO_ICALL                                         $30     
         51*       ASSIGN                                                   !5, $30
   42    52*       CONCAT                                           ~32     '%E5%8F%AF%E8%AF%BB%E7%A0%81%EF%BC%9A', !5
         53*       CONCAT                                           ~33     ~32, '%3Cbr+%2F%3E'
         54*       ECHO                                                     ~33
   44    55*       ECHO                                                     '%3Cbr+%2F%3E%E8%B0%B7%E6%AD%8C%E5%85%B3%E9%94%AE%E8%AF%8DURL%E7%BC%96%E7%A0%81%E8%BD%AC%E6%8D%A2%E7%A4%BA%E4%BE%8B%EF%BC%9A%3Cbr+%2F%3E'
   46    56*       ASSIGN                                                   !6, 'http%3A%2F%2Fwww.google.cn%2Fsearch%3Fhl%3Dzh-CN%26source%3Dhp%26q%3D%25E4%25B8%25AD%25E6%2596%2587%26aq%3Df%26oq%3D'
   48    57*       INIT_FCALL                                               'parse_url'
         58*       SEND_VAR                                                 !6
         59*       DO_ICALL                                         $35     
         60*       ASSIGN                                                   !3, $35
   49    61*       INIT_FCALL                                               'var_dump'
         62*       SEND_VAR                                                 !3
         63*       DO_ICALL                                                 
   50    64*       INIT_FCALL                                               'parse_str'
         65*       FETCH_DIM_R                                      ~38     !3, 'query'
         66*       SEND_VAL                                                 ~38
         67*       SEND_REF                                                 !4
         68*       DO_ICALL                                                 
         69*       INIT_FCALL                                               'var_dump'
         70*       SEND_VAR                                                 !4
         71*       DO_ICALL                                                 
   53    72*       FETCH_DIM_R                                      ~41     !4, 'q'
         73*       CONCAT                                           ~42     '%E5%8F%AF%E8%AF%BB%E7%A0%81%EF%BC%9A', ~41
         74*       CONCAT                                           ~43     ~42, '%3Cbr+%2F%3E'
         75*       ECHO                                                     ~43
   55    76*       ASSIGN                                           ~44     !7, 'This+contains+a+%09+tab+character.'
         77*       ECHO                                                     ~44
   56    78*       ASSIGN                                           ~45     !8, 'This+just+contains+a+slash+and+a+t%3A+%5Ct'
         79*       ECHO                                                     ~45
         80*     > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
156.61 ms | 1404 KiB | 23 Q