如果你下载下来了,你一定要善待这只鸡。下载下来打开就可以聊天!我放到了我的服务器上,国庆期间我无聊就找鸡。
http://www.wbaobao.top/talkjj/
代码核心就是调用接口跟前台的输出js的使用方法。
它可能没有你想象的那么黄,最黄的在韩国。display();
}
public function data(){
if (is_post) {
$appkey = 5e70fea5553d2deea473c13b516a564a;
$url = http://op.juhe.cn/robot/index;
$metock=i(post.txt,haha);
$params = array(
key => $appkey,//您申请到的本接口专用的appkey
info => $metock,//要发送给机器人的内容,不要超过30个字符
dtype => ,//返回的数据的格式,json或xml,默认为json
loc => ,//地点,如北京中关村
lon => ,//经度,东经116.234632(小数点后保留6位),需要写为116234632
lat => ,//纬度,北纬40.234632(小数点后保留6位),需要写为40234632
userid => ,//1~32位,此userid针对您自己的每一个用户,用于上下文的关联
);
$params=http_build_query($params);
$ispost=0;
$httpinfo = array();
$ch = curl_init();
curl_setopt( $ch, curlopt_http_version , curl_http_version_1_1 );
curl_setopt( $ch, curlopt_useragent , 'juhedata' );
curl_setopt( $ch, curlopt_connecttimeout , 60 );
curl_setopt( $ch, curlopt_timeout , 60);
curl_setopt( $ch, curlopt_returntransfer , true );
curl_setopt($ch, curlopt_followlocation, true);
curl_setopt( $ch , curlopt_url , $url.'?'.$params );
$response = curl_exec( $ch );
if ($response === false) {
return false;
}
$httpcode = curl_getinfo( $ch , curlinfo_http_code );
$httpinfo = array_merge( $httpinfo , curl_getinfo( $ch ) );
curl_close( $ch );
$data=json_decode($response,ture)[result][text];
$return=[
text=>$data,
];
$this->ajaxreturn($return);
}
}
}
talkjj.rar ( 1.25 mb 下载:63 次 )