火狐线路

This commit is contained in:
“wanyongkang”
2022-04-14 18:06:46 +08:00
parent 9fa202f23b
commit 386ceeac70
2 changed files with 11 additions and 2 deletions

View File

@@ -215,7 +215,12 @@ function format_product($file_path, $dns = '')
$data['status'] = $info[8] ?? '';
if ($dns != 'shihui') {
$ip = explode('.', ($info[9] ?? ''));
$data['nasname'] = $ip[0] ? ip_repeat($record, $ip[0]) . '.' . $dns : '';
if (count($ip) == 4) {
$data['nasname'] = $info[9];
} else {
$data['nasname'] = $ip[0] ? ip_repeat($record, $ip[0]) . '.' . $dns : '';
}
} else {
$data['nasname'] = $info[9] ?? '';
}

View File

@@ -5,7 +5,7 @@
* @Author: kangkang
* @Date: 2020-11-06 14:32:57
* @LastEditors: Please set LastEditors
* @LastEditTime: 2020-11-27 10:32:41
* @LastEditTime: 2022-04-14 17:50:48
*/
header('Access-Control-Allow-Origin: *');
header("Access-Control-Allow-Methods: *");
@@ -58,6 +58,10 @@ switch ($id) {
case 19:
get_product(__DIR__ . '/data/download/huohu.csv');
break;
case 22:
get_product(__DIR__ . '/data/download/huohu.csv');
break;
}
function get_all_product($file_path)