Answers for "json text to php"

PHP
0

php decode json object

<?php

$json = '{"firstName":"Peter","lastName:":"Silva","age":23}';

$personInfo = json_decode(json);

echo $personInfo->age;

?>
Posted by: Guest on October-22-2020
0

parse json phph

echo json_decode("[1,2,3]")[0];
Posted by: Guest on January-15-2020

Browse Popular Code Answers by Language