基于php的最新电影接口调用代码实例
代码描述:基于php的最新电影接口调用代码实例
接口平台:聚合数据
<!--?php
// +----------------------------------------------------------------------
// | JuhePHP [ NO ZUO NO DIE ]
// +----------------------------------------------------------------------
// | Copyright (c) 2010-2015 All rights reserved.
// +----------------------------------------------------------------------
// | Author: Juhedata <info@-->
// +----------------------------------------------------------------------
//----------------------------------
// 影讯API合集调用示例代码- 聚合数据
// 在线接口文档:s/42
//----------------------------------
header('Content-type:text/html;charset=utf-8');
//配置您申请的appkey
$appkey = "*********************";
//************************
$url = "http://v./movie/index";
$params = array(
"title" => "",//需要检索的影片标题,utf8编码的urlencode
"smode" => "",//<font color=red>是否精确查找,精确:1 模糊:0 默认1</font>
"pagesize" => "",//<font color=red>每次返回条数,默认20,最大50</font>
"offset" => "",//<font color=red>偏移量,默认0,最大760</font>
"key" => $appkey,//应用APPKEY(应用详细页查询)
"dtype" => "",//返回数据的格式,xml/json,默认json
);
$paramstring = http_build_query($params);
$content = juhecurl($url,$paramstring);
$result = json_decode($content,true);
if($result){
if($result['error_code']=='0'){
print_r($result);
}else{
echo $result['error_
基于php的最新电影接口调用代码实例 来自淘豆网m.daumloan.com转载请标明出处.