3v4l.org

run code in 300+ PHP versions simultaneously
<?php $user_ip = getenv('REMOTE_ADDR'); $geo = unserialize(file_get_contents("http://www.geoplugin.net/php.gp?ip=$user_ip")); $city = $geo["geoplugin_city"]; $region = $geo["geoplugin_regionName"]; $country = $geo["geoplugin_countryName"]; echo "City: ".$city."<br>"; echo "Region: ".$region."<br>"; echo "Country: ".$country."<br>"; /* geoplugin_request geoplugin_status geoplugin_credit geoplugin_city geoplugin_region geoplugin_areaCode geoplugin_dmaCode geoplugin_countryCode geoplugin_countryName geoplugin_continentCode geoplugin_latitude geoplugin_longitude geoplugin_regionCode geoplugin_regionName geoplugin_currencyCode geoplugin_currencySymbol geoplugin_currencySymbol_UTF8 geoplugin_currencyConverter */ ?>
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/H7cVk
function name:  (null)
number of ops:  29
compiled vars:  !0 = $user_ip, !1 = $geo, !2 = $city, !3 = $region, !4 = $country
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   INIT_FCALL                                               'getenv'
          1        SEND_VAL                                                 'REMOTE_ADDR'
          2        DO_ICALL                                         $5      
          3        ASSIGN                                                   !0, $5
    3     4        INIT_FCALL                                               'unserialize'
          5        INIT_FCALL                                               'file_get_contents'
          6        NOP                                                      
          7        FAST_CONCAT                                      ~7      'http%3A%2F%2Fwww.geoplugin.net%2Fphp.gp%3Fip%3D', !0
          8        SEND_VAL                                                 ~7
          9        DO_ICALL                                         $8      
         10        SEND_VAR                                                 $8
         11        DO_ICALL                                         $9      
         12        ASSIGN                                                   !1, $9
    4    13        FETCH_DIM_R                                      ~11     !1, 'geoplugin_city'
         14        ASSIGN                                                   !2, ~11
    5    15        FETCH_DIM_R                                      ~13     !1, 'geoplugin_regionName'
         16        ASSIGN                                                   !3, ~13
    6    17        FETCH_DIM_R                                      ~15     !1, 'geoplugin_countryName'
         18        ASSIGN                                                   !4, ~15
    7    19        CONCAT                                           ~17     'City%3A+', !2
         20        CONCAT                                           ~18     ~17, '%3Cbr%3E'
         21        ECHO                                                     ~18
    8    22        CONCAT                                           ~19     'Region%3A+', !3
         23        CONCAT                                           ~20     ~19, '%3Cbr%3E'
         24        ECHO                                                     ~20
    9    25        CONCAT                                           ~21     'Country%3A+', !4
         26        CONCAT                                           ~22     ~21, '%3Cbr%3E'
         27        ECHO                                                     ~22
   30    28      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
172.32 ms | 1390 KiB | 20 Q