3v4l.org

run code in 300+ PHP versions simultaneously
<?php echo "Hello world"; ?> <table> <?php //This is our first loop, changing the R value $r=15; while ($r <= 255) { echo "<tr>"; //Our third loop (B value) occurs 6 times for ever G value, or 216 times $b=15; while ($b <= 255) { //Here we actually generate the color blocks $background = str_pad((string)dechex($r), 2, "0", STR_PAD_LEFT) . F . F . str_pad((string)dechex($b), 2, "0", STR_PAD_LEFT); echo "<td bgcolor=\"#$background\">#$background</td>"; //At the end of each loop we add 3 $b = $b+16; } $r = $r+16; echo "</tr>"; } ?> </table> <p> <a href="http://www.goatella.com">Goatella's Home Page</a><p> <a href="https://github.com/Goatella/PHP-Hex">This script on GitHub</a>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 42) Position 1 = 46
Branch analysis from position: 46
2 jumps found. (Code = 44) Position 1 = 48, Position 2 = 4
Branch analysis from position: 48
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 4
1 jumps found. (Code = 42) Position 1 = 41
Branch analysis from position: 41
2 jumps found. (Code = 44) Position 1 = 43, Position 2 = 7
Branch analysis from position: 43
2 jumps found. (Code = 44) Position 1 = 48, Position 2 = 4
Branch analysis from position: 48
Branch analysis from position: 4
Branch analysis from position: 7
2 jumps found. (Code = 44) Position 1 = 43, Position 2 = 7
Branch analysis from position: 43
Branch analysis from position: 7
filename:       /in/Zku49
function name:  (null)
number of ops:  50
compiled vars:  !0 = $r, !1 = $b, !2 = $background
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    1     0  E >   ECHO                                                     'Hello+world'
    2     1        ECHO                                                     '+%3Ctable%3E+%0A+'
    5     2        ASSIGN                                                   !0, 15
    6     3      > JMP                                                      ->46
    8     4    >   ECHO                                                     '%3Ctr%3E'
   12     5        ASSIGN                                                   !1, 15
   13     6      > JMP                                                      ->41
   18     7    >   INIT_FCALL                                               'str_pad'
          8        INIT_FCALL                                               'dechex'
          9        SEND_VAR                                                 !0
         10        DO_ICALL                                         $5      
         11        CAST                                          6  ~6      $5
         12        SEND_VAL                                                 ~6
         13        SEND_VAL                                                 2
         14        SEND_VAL                                                 '0'
         15        SEND_VAL                                                 0
         16        DO_ICALL                                         $7      
         17        FETCH_CONSTANT                                   ~8      'F'
         18        CONCAT                                           ~9      $7, ~8
         19        FETCH_CONSTANT                                   ~10     'F'
         20        CONCAT                                           ~11     ~9, ~10
         21        INIT_FCALL                                               'str_pad'
         22        INIT_FCALL                                               'dechex'
         23        SEND_VAR                                                 !1
         24        DO_ICALL                                         $12     
         25        CAST                                          6  ~13     $12
         26        SEND_VAL                                                 ~13
         27        SEND_VAL                                                 2
         28        SEND_VAL                                                 '0'
         29        SEND_VAL                                                 0
         30        DO_ICALL                                         $14     
         31        CONCAT                                           ~15     ~11, $14
         32        ASSIGN                                                   !2, ~15
   19    33        ROPE_INIT                                     5  ~18     '%3Ctd+bgcolor%3D%22%23'
         34        ROPE_ADD                                      1  ~18     ~18, !2
         35        ROPE_ADD                                      2  ~18     ~18, '%22%3E%23'
         36        ROPE_ADD                                      3  ~18     ~18, !2
         37        ROPE_END                                      4  ~17     ~18, '%3C%2Ftd%3E'
         38        ECHO                                                     ~17
   22    39        ADD                                              ~21     !1, 16
         40        ASSIGN                                                   !1, ~21
   13    41    >   IS_SMALLER_OR_EQUAL                                      !1, 255
         42      > JMPNZ                                                    ~23, ->7
   24    43    >   ADD                                              ~24     !0, 16
         44        ASSIGN                                                   !0, ~24
   25    45        ECHO                                                     '%3C%2Ftr%3E'
    6    46    >   IS_SMALLER_OR_EQUAL                                      !0, 255
         47      > JMPNZ                                                    ~26, ->4
   28    48    >   ECHO                                                     '+%3C%2Ftable%3E+%0A%0A%0A%3Cp%3E%0A%3Ca+href%3D%22http%3A%2F%2Fwww.goatella.com%22%3EGoatella%27s+Home+Page%3C%2Fa%3E%3Cp%3E%0A%3Ca+href%3D%22https%3A%2F%2Fgithub.com%2FGoatella%2FPHP-Hex%22%3EThis+script+on+GitHub%3C%2Fa%3E'
   33    49      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
149.65 ms | 1400 KiB | 17 Q