3v4l.org

run code in 300+ PHP versions simultaneously
<?php // $fileContent = file_get_contents( plik ) $fileContent = '{ "glossary": { "title": "example glossary", "GlossDiv": { "title": "S", "content": "P" } } }'; $parsedArray = json_decode($fileContent); print_r($parsedArray); echo str_repeat("=", 50); $parsedArray->glossary->title = "heheszki"; $parsedArray->glossary->GlossDiv->title = "Testujemy"; $parsedArray->glossary->GlossDiv->content = "Testujemy"; print_r($parsedArray); echo json_encode($parsedArray);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/R9DQW
function name:  (null)
number of ops:  32
compiled vars:  !0 = $fileContent, !1 = $parsedArray
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    4     0  E >   ASSIGN                                                   !0, '%7B%0A++++%22glossary%22%3A+%7B%0A++++++++%22title%22%3A+%22example+glossary%22%2C%0A%09%09%22GlossDiv%22%3A+%7B%0A++++++++++++%22title%22%3A+%22S%22%2C%0A%09%09%09%22content%22%3A+%22P%22%0A++++++++++++%7D%0A%0A++++%7D%0A%7D'
   15     1        INIT_FCALL                                               'json_decode'
          2        SEND_VAR                                                 !0
          3        DO_ICALL                                         $3      
          4        ASSIGN                                                   !1, $3
   16     5        INIT_FCALL                                               'print_r'
          6        SEND_VAR                                                 !1
          7        DO_ICALL                                                 
   17     8        INIT_FCALL                                               'str_repeat'
          9        SEND_VAL                                                 '%3D'
         10        SEND_VAL                                                 50
         11        DO_ICALL                                         $6      
         12        ECHO                                                     $6
   18    13        FETCH_OBJ_W                                      $7      !1, 'glossary'
         14        ASSIGN_OBJ                                               $7, 'title'
         15        OP_DATA                                                  'heheszki'
   19    16        FETCH_OBJ_W                                      $9      !1, 'glossary'
         17        FETCH_OBJ_W                                      $10     $9, 'GlossDiv'
         18        ASSIGN_OBJ                                               $10, 'title'
         19        OP_DATA                                                  'Testujemy'
   20    20        FETCH_OBJ_W                                      $12     !1, 'glossary'
         21        FETCH_OBJ_W                                      $13     $12, 'GlossDiv'
         22        ASSIGN_OBJ                                               $13, 'content'
         23        OP_DATA                                                  'Testujemy'
   22    24        INIT_FCALL                                               'print_r'
         25        SEND_VAR                                                 !1
         26        DO_ICALL                                                 
   23    27        INIT_FCALL                                               'json_encode'
         28        SEND_VAR                                                 !1
         29        DO_ICALL                                         $16     
         30        ECHO                                                     $16
         31      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
149.21 ms | 1014 KiB | 17 Q