3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $myArr = array( "success" => ( object ) array( "id" => "success=-message", "class" => "success-message", "inner-html" => "Congratulations! You have been succesfully logged in" ), "class" => ( object ) array( "id" => "success=-message", "class" => "success-message", "inner-html" => "Congratulations! You have been succesfully logged in" ), ); //Now you output the json version echo json_encode( $myArr );
based on tUZUQ
Finding entry points
Branch analysis from position: 0
Jump found. Position 1 = -2
filename:       /in/ddPbl
function name:  (null)
number of ops:  10
compiled vars:  !0 = $myArr
line     #* E I O op                           fetch          ext  return  operands
-------------------------------------------------------------------------------------
   4     0  E >   CAST                                          8  ~1      <array>
         1        INIT_ARRAY                                       ~2      ~1, 'success'
  10     2        CAST                                          8  ~3      <array>
         3        ADD_ARRAY_ELEMENT                                ~2      ~3, 'class'
         4        ASSIGN                                                   !0, ~2
  18     5        INIT_FCALL                                               'json_encode'
         6        SEND_VAR                                                 !0
         7        DO_ICALL                                         $5      
         8        ECHO                                                     $5
         9      > RETURN                                                   1

Generated using Vulcan Logic Dumper, using php 7.2.0