3v4l.org

run code in 300+ PHP versions simultaneously
<?php function getBTCValue() { $url = 'http://middlecoin.com'; $contents = file_get_contents($url); preg_match_all('/<td>(.*?)<\/td>/s', $contents, $matches); $ex = explode(" ", strip_tags($matches[0][0])); $output .= "<span style='color:red; font-weight:bold;'>Balance:</span> ".$matches[0][5]."<br>"; $output .= "<span style='color:#3399ff; font-weight:bold;'>Unexchanged:</span> ".$matches[0][4]."<br>"; $output = "<span style='color:#51d051; font-weight:bold;'>Immature:</span> ".$matches[0][3]."<br>"; $output .= "<span style='color:#000000; font-weight:bold;'>Paid:</span> ".$matches[0][6]."<br>"; return $output; } var_dump(getBTCValue());
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/6BWBu
function name:  (null)
number of ops:  6
compiled vars:  none
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   17     0  E >   INIT_FCALL                                               'var_dump'
          1        INIT_FCALL                                               'getbtcvalue'
          2        DO_FCALL                                      0  $0      
          3        SEND_VAR                                                 $0
          4        DO_ICALL                                                 
          5      > RETURN                                                   1

Function getbtcvalue:
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/6BWBu
function name:  getBTCValue
number of ops:  42
compiled vars:  !0 = $url, !1 = $contents, !2 = $matches, !3 = $ex, !4 = $output
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   ASSIGN                                                   !0, 'http%3A%2F%2Fmiddlecoin.com'
    5     1        INIT_FCALL                                               'file_get_contents'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $6      
          4        ASSIGN                                                   !1, $6
    6     5        INIT_FCALL                                               'preg_match_all'
          6        SEND_VAL                                                 '%2F%3Ctd%3E%28.%2A%3F%29%3C%5C%2Ftd%3E%2Fs'
          7        SEND_VAR                                                 !1
          8        SEND_REF                                                 !2
          9        DO_ICALL                                                 
    7    10        INIT_FCALL                                               'explode'
         11        SEND_VAL                                                 '+'
         12        INIT_FCALL                                               'strip_tags'
         13        FETCH_DIM_R                                      ~9      !2, 0
         14        FETCH_DIM_R                                      ~10     ~9, 0
         15        SEND_VAL                                                 ~10
         16        DO_ICALL                                         $11     
         17        SEND_VAR                                                 $11
         18        DO_ICALL                                         $12     
         19        ASSIGN                                                   !3, $12
    9    20        FETCH_DIM_R                                      ~14     !2, 0
         21        FETCH_DIM_R                                      ~15     ~14, 5
         22        CONCAT                                           ~16     '%3Cspan+style%3D%27color%3Ared%3B+font-weight%3Abold%3B%27%3EBalance%3A%3C%2Fspan%3E+', ~15
         23        CONCAT                                           ~17     ~16, '%3Cbr%3E'
         24        ASSIGN_OP                                     8          !4, ~17
   10    25        FETCH_DIM_R                                      ~19     !2, 0
         26        FETCH_DIM_R                                      ~20     ~19, 4
         27        CONCAT                                           ~21     '%3Cspan+style%3D%27color%3A%233399ff%3B+font-weight%3Abold%3B%27%3EUnexchanged%3A%3C%2Fspan%3E+', ~20
         28        CONCAT                                           ~22     ~21, '%3Cbr%3E'
         29        ASSIGN_OP                                     8          !4, ~22
   11    30        FETCH_DIM_R                                      ~24     !2, 0
         31        FETCH_DIM_R                                      ~25     ~24, 3
         32        CONCAT                                           ~26     '%3Cspan+style%3D%27color%3A%2351d051%3B+font-weight%3Abold%3B%27%3EImmature%3A%3C%2Fspan%3E+', ~25
         33        CONCAT                                           ~27     ~26, '%3Cbr%3E'
         34        ASSIGN                                                   !4, ~27
   12    35        FETCH_DIM_R                                      ~29     !2, 0
         36        FETCH_DIM_R                                      ~30     ~29, 6
         37        CONCAT                                           ~31     '%3Cspan+style%3D%27color%3A%23000000%3B+font-weight%3Abold%3B%27%3EPaid%3A%3C%2Fspan%3E+', ~30
         38        CONCAT                                           ~32     ~31, '%3Cbr%3E'
         39        ASSIGN_OP                                     8          !4, ~32
   14    40      > RETURN                                                   !4
   15    41*     > RETURN                                                   null

End of function getbtcvalue

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
153.01 ms | 1403 KiB | 24 Q