Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/json/13.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Php Youtube API v3-检索频道名称_Php_Json_Youtube - Fatal编程技术网

Php Youtube API v3-检索频道名称

Php Youtube API v3-检索频道名称,php,json,youtube,Php,Json,Youtube,我需要获得频道名称(标题)的帮助。我想用json\u decode来做,但我不知道怎么做。请帮帮我:)谢谢:) 真诚地说,我更喜欢使用CURL而不是“file\u get\u contents”,它更灵活 关于json_decode,如果您想使用对象,那么就去掉第二个参数。“YES”参数强制将结果作为数组而不是对象 json_decode($json) 如果使用第二个参数,则: $result = json_decode($json,YES) var_dump($result); 您将

我需要获得频道名称(标题)的帮助。我想用
json\u decode
来做,但我不知道怎么做。请帮帮我:)谢谢:)


真诚地说,我更喜欢使用CURL而不是“file\u get\u contents”,它更灵活

关于json_decode,如果您想使用对象,那么就去掉第二个参数。“YES”参数强制将结果作为数组而不是对象

json_decode($json)
如果使用第二个参数,则:

$result = json_decode($json,YES) 

var_dump($result);

您将看到一个数组。

我更喜欢使用CURL而不是“file\u get\u contents”,它更灵活

关于json_decode,如果您想使用对象,那么就去掉第二个参数。“YES”参数强制将结果作为数组而不是对象

json_decode($json)
如果使用第二个参数,则:

$result = json_decode($json,YES) 

var_dump($result);
您将看到一个数组