主页
PHP
PHP 和 JSON
tryphp_json_decode2
运行 ❯
×
更改方向
保存代码
更改主题
<!DOCTYPE html> <html> <body> <?php $jsonobj = '{"Peter":35,"Ben":37,"Joe":43}'; var_dump(json_decode($jsonobj, true)); ?> </body> </html>
array(3) { ["Peter"]=> int(35) ["Ben"]=> int(37) ["Joe"]=> int(43) }