1
현재
$big_test = array(
'username' => 'test',
'password' => 'test'
);
$test = json_encode($big_test);
echo $test;
결과는 다음과 같습니다.
{"username":"test","password":"test"}
하지만 결과가 랩핑 될 데이터가있을 수 있습니다.이
{"Results":[{"username":"test","password":"test"}]}
확인하는 방법과 디코딩 된 버전을 인쇄하는 방법? $ decode [ 'Results'] [ 'password']; ?? – codecute
var_dump (json_decode ($ test)); – B4NZ41
$ decode [ 'Results'] [0] [ 'password']; – SergeS