我在PHP中运行CURL,如果我6
回复,我会得到以下内容,并且我保存为var_dump
:
$response
我需要做的是获取{
"name": "Bob Smithy",
"email": "testing@gmail.com",
"email_verified": false,
"connection": "Username-Password-Authentication",
"user_id": "f8d305bb49a3",
"provider": "auth0",
"picture": "https://secure.gravatar.com/avatar/a2da375af0228d88aed6b723e6764a94?s=480&r=pg&d=https%3A%2F%2Fcdn.auth0.com%2Favatars%2Fbs.png",
"nickname": "Bob Smithy",
"identities": [
{
"connection": "Username-Password-Authentication",
"user_id": "f8d305bb49a3",
"provider": "auth0",
"isSocial": false
}
],
"updated_at": "2015-08-05T21:11:56.202Z",
"created_at": "2015-08-05T21:11:56.202Z"
}
下user_id
的价值。我知道我需要做identities
,但后来我无法弄清楚如何构建其余部分。我知道这不起作用:
json_decode
我应该在这做什么才能获得这个价值?