开发者

Get Total Results Youtube Api PHP

Hey, well right now I'm parsing youtube's api

demo url :

http://gdata.youtube.com/feeds/api开发者_JS百科/videos/-/test?orderby=viewCount&start-index=1&max-results=50

i'm using simplexml_load_file

the thing is, what should i do to retrieve the

<openSearch:totalResults>9477</openSearch:totalResults>

any ideas?

Thanks


$feedURL = "http://gdata.youtube.com/feeds/api/videos?q=test&orderby=viewCount&start-index=1&max-results=1";
$sxml = simplexml_load_file($feedURL);
$counts = $sxml->children('http://a9.com/-/spec/opensearchrss/1.0/');
$total = $counts->totalResults;
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜