3v4l.org

run code in 300+ PHP versions simultaneously
<?php if (isset($_SERVER['HTTP_CLIENT_IP'])) { return $_SERVER['HTTP_CLIENT_IP']; } // IP derrière un proxy elseif (isset($_SERVER['HTTP_X_FORWARDED_FOR'])) { return $_SERVER['HTTP_X_FORWARDED_FOR']; } // Sinon : IP normale else { return (isset($_SERVER['REMOTE_ADDR']) ? $_SERVER['REMOTE_ADDR'] : ''); }
Finding entry points
Branch analysis from position: 0
2 jumps found. (Code = 43) Position 1 = 3, Position 2 = 7
Branch analysis from position: 3
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 7
2 jumps found. (Code = 43) Position 1 = 10, Position 2 = 14
Branch analysis from position: 10
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 14
2 jumps found. (Code = 43) Position 1 = 17, Position 2 = 21
Branch analysis from position: 17
1 jumps found. (Code = 42) Position 1 = 22
Branch analysis from position: 22
1 jumps found. (Code = 62) Position 1 = -2
Branch analysis from position: 21
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/iUs5a
function name:  (null)
number of ops:  24
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    3     0  E >   FETCH_IS                                         ~0      '_SERVER'
          1        ISSET_ISEMPTY_DIM_OBJ                         0          ~0, 'HTTP_CLIENT_IP'
          2      > JMPZ                                                     ~1, ->7
    4     3    >   FETCH_R                      global              ~2      '_SERVER'
          4        FETCH_DIM_R                                      ~3      ~2, 'HTTP_CLIENT_IP'
          5      > RETURN                                                   ~3
          6*       JMP                                                      ->23
    7     7    >   FETCH_IS                                         ~4      '_SERVER'
          8        ISSET_ISEMPTY_DIM_OBJ                         0          ~4, 'HTTP_X_FORWARDED_FOR'
          9      > JMPZ                                                     ~5, ->14
    8    10    >   FETCH_R                      global              ~6      '_SERVER'
         11        FETCH_DIM_R                                      ~7      ~6, 'HTTP_X_FORWARDED_FOR'
         12      > RETURN                                                   ~7
         13*       JMP                                                      ->23
   12    14    >   FETCH_IS                                         ~8      '_SERVER'
         15        ISSET_ISEMPTY_DIM_OBJ                         0          ~8, 'REMOTE_ADDR'
         16      > JMPZ                                                     ~9, ->21
         17    >   FETCH_R                      global              ~10     '_SERVER'
         18        FETCH_DIM_R                                      ~11     ~10, 'REMOTE_ADDR'
         19        QM_ASSIGN                                        ~12     ~11
         20      > JMP                                                      ->22
         21    >   QM_ASSIGN                                        ~12     ''
         22    > > RETURN                                                   ~12
   13    23*     > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
172.08 ms | 1385 KiB | 13 Q