<?php
//处理json
$json='[{"USERNAME":"user1","PASSWORD":"123"},{"USERNAME":"user2","PASSWORD":"234"}]';
$str=json_decode($json);
print_r($str);
foreach($str as $obj)
{
echo "姓名:".$obj->USERNAME;
}
//处理json
$json='[{"USERNAME":"user1","PASSWORD":"123"},{"USERNAME":"user2","PASSWORD":"234"}]';
$str=json_decode($json);
print_r($str);
foreach($str as $obj)
{
echo "姓名:".$obj->USERNAME;
}
?>