3v4l.org

run code in 300+ PHP versions simultaneously
<?php $keyword = "täglich"; $json = array("context" => array(array("paragraph" => array(array("sentence" => array($keyword))) )) ); $json = json_encode($json); $query = '{ "context": [ { "paragraph": [ { "sentence": [ '.$keyword.' ] } ] } ] }'; print_r($json);
Finding entry points
Branch analysis from position: 0
1 jumps found. (Code = 62) Position 1 = -2
filename:       /in/v1Ugf
function name:  (null)
number of ops:  19
compiled vars:  !0 = $keyword, !1 = $json, !2 = $query
line      #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
    2     0  E >   ASSIGN                                                   !0, 't%C3%A4glich'
    4     1        INIT_ARRAY                                       ~4      !0
          2        INIT_ARRAY                                       ~5      ~4, 'sentence'
          3        INIT_ARRAY                                       ~6      ~5
          4        INIT_ARRAY                                       ~7      ~6, 'paragraph'
          5        INIT_ARRAY                                       ~8      ~7
          6        INIT_ARRAY                                       ~9      ~8, 'context'
          7        ASSIGN                                                   !1, ~9
    5     8        INIT_FCALL                                               'json_encode'
          9        SEND_VAR                                                 !1
         10        DO_ICALL                                         $11     
         11        ASSIGN                                                   !1, $11
    6    12        CONCAT                                           ~13     '%7B+%22context%22%3A+%5B+%7B+%22paragraph%22%3A+%5B+%7B+%22sentence%22%3A+%5B+', !0
         13        CONCAT                                           ~14     ~13, '+%5D+%7D+%5D+%7D+%5D+%7D'
         14        ASSIGN                                                   !2, ~14
    7    15        INIT_FCALL                                               'print_r'
         16        SEND_VAR                                                 !1
         17        DO_ICALL                                                 
         18      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 8.0.0


preferences:
152.09 ms | 1395 KiB | 17 Q