This commit is contained in:
“wanyongkang”
2022-04-28 17:58:53 +08:00
parent 0d0572f1ed
commit 1277d0532b
4 changed files with 26 additions and 26 deletions

View File

@@ -53,7 +53,7 @@ function auto_format_list(){
format_product(__DIR__ . '/data/huohu.csv','hhip.vip');
break;
case 23:
format_product(__DIR__ . '/data/liebao.csv','lbip.vip');
format_product(__DIR__ . '/data/yunniu.csv','ynip.net');
break;
}
}
@@ -115,8 +115,8 @@ function format_all_product($file_path)
$dns = 'hhip.vip';
break;
case '猎豹':
$dns = 'lbip.vip';
case '云牛':
$dns = 'ynip.net';
break;
default:
$dns = 'xlip.vip';

View File

@@ -5,7 +5,7 @@
* @Author: kangkang
* @Date: 2020-11-06 14:32:57
* @LastEditors: Please set LastEditors
* @LastEditTime: 2022-04-28 17:37:42
* @LastEditTime: 2022-04-28 17:58:19
*/
header('Access-Control-Allow-Origin: *');
header("Access-Control-Allow-Methods: *");
@@ -64,7 +64,7 @@ switch ($id) {
break;
case 23:
get_product(__DIR__ . '/data/download/liebao.csv');
get_product(__DIR__ . '/data/download/yunniu.csv');
break;
}

View File

@@ -5,7 +5,7 @@
* @Author: kangkang
* @Date: 2020-11-03 11:04:15
* @LastEditors: Please set LastEditors
* @LastEditTime: 2022-04-28 17:39:37
* @LastEditTime: 2022-04-28 17:57:51
*/
$is_script = 1;
include_once __DIR__ . '/../../index.php';
@@ -14,19 +14,19 @@ include_once __DIR__ . '/auto_format.php';
// //测试用----------------------------------------------------------------------------------------------------------
$url = 'http://int.linghangsoft.net:8000/sysadmin/useradmin/lineapi_admin1.php?secretId=108006113&secretKey=87085a351a64c116df09ebc07d5781sf';
$liebao = json_decode(file_get_contents($url), true);
// $url = 'http://int.linghangsoft.net:8000/sysadmin/useradmin/lineapi_admin1.php?secretId=108006113&secretKey=87085a351a64c116df09ebc07d5781sf';
// $yunniu = json_decode(file_get_contents($url), true);
if(!empty($liebao)){
$liebao_f = fopen(__DIR__ . '/data/liebao.csv', 'w');
//写入火狐文件
$liebao_data = get_product(__DIR__ . '/data/liebao.csv');
huohu_getList($liebao, $liebao_f, $all,$liebao_data);
fclose($liebao_f);
}
// if(!empty($yunniu)){
// $yunniu_f = fopen(__DIR__ . '/data/yunniu.csv', 'w');
// //写入火狐文件
// $yunniu_data = get_product(__DIR__ . '/data/yunniu.csv');
// huohu_getList($yunniu, $yunniu_f, $all,$yunniu_data);
// fclose($yunniu_f);
// }
die;
// die;
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
//强子迅联特征码
$sp_xl_code = file_get_contents(__DIR__ . '/data/xl.txt', 'r');
@@ -113,15 +113,15 @@ if(!empty($huohu)){
///动态
$url = 'http://int.linghangsoft.net:8000/sysadmin/useradmin/lineapi_admin1.php?secretId=108006113&secretKey=87085a351a64c116df09ebc07d5781sf';
$liebao = json_decode(file_get_contents($url), true);
$yunniu = json_decode(file_get_contents($url), true);
if(!empty($liebao)){
$liebao_f = fopen(__DIR__ . '/data/liebao.csv', 'w');
if(!empty($yunniu)){
$yunniu_f = fopen(__DIR__ . '/data/yunniu.csv', 'w');
//写入火狐文件
$liebao_data = get_product(__DIR__ . '/data/liebao.csv');
huohu_getList($liebao, $liebao_f, $all,$liebao_data);
fclose($liebao_f);
$yunniu_data = get_product(__DIR__ . '/data/yunniu.csv');
huohu_getList($yunniu, $yunniu_f, $all,$yunniu_data);
fclose($yunniu_f);
}
@@ -295,7 +295,7 @@ function huohu_getList($data, &$file, &$all, $exit)
$province_record = [];
foreach ($data as $info){
$record = [];
$record['name'] = '猎豹';
$record['name'] = '云牛';
//如果存在 不为空 则
if (!in_array( $info['province'], $province_record)) {
$record['city'] = $info['province'];

View File

@@ -67,7 +67,7 @@ if($_GET['type'] == 1){
break;
case 23:
search_product(__DIR__ . '/data/download/liebao.csv','lbip.vip');
search_product(__DIR__ . '/data/download/yunniu.csv','ynip.net');
break;
}
}
@@ -137,8 +137,8 @@ function search_all_product($file_path,$search){
$dns = 'hhip.vip';
break;
case '猎豹':
$dns = 'lbip.vip';
case '云牛':
$dns = 'ynip.net';
break;
}