Caracorn
6 months ago

How to print all data of this JSON-structure?

Posted 6 months ago by Caracorn

Hello,

how can I read comfortably the data of this JSON-response in Laravel? Thank you!

$resp_json = (json_decode($response));

// STRING OF $resp_json // // stdClass Object( // [ data ] => Array( // [ 0 ] => stdClass Object( // [ id ] => 1 // [ article_number ] => 1234567890 // [ name ] => Testarticle // #1 // [short_description] => Lorem ipsum dolor sit amet // [description] => Lorem ipsum dolor sit amet ... // [type] => digital // [pricing] => stdClass Object ( // [1] => stdClass Object ( // [salesprice] => NULL // [salesprice_net] => NULL // [salesprice_points] => NULL // [salesprice_shipping] => NULL // ) // [default] => stdClass Object ( // [salesprice] => NULL // [salesprice_net] => NULL // [salesprice_points] => NULL // [salesprice_shipping] => NULL // ) // ) // [categories] => Array ( // [0] => stdClass Object ( // [id] => 1 // [name] => Travel // ) // ) // [images] => Array ( ) // ) // ) // )

Please sign in or create an account to participate in this conversation.