NEED_LOGIN code add

This commit is contained in:
knowpia
2022-09-09 11:20:20 +08:00
parent 4f6026dbff
commit dc3f8140a0
3 changed files with 72 additions and 1 deletions

View File

@@ -17,6 +17,17 @@ class Search
}else{
$where = "id < ".$lastIndex;
}
$types = [1,2,3,4];
if(!empty($GLOBALS['data']['data']["type"])){
$type = $GLOBALS['data']['data']["type"];
if(!in_array($type, $types)){
return show("上传的类型不正确");
}
if($type == 1) $where .= " and type = 1";
if($type == 2) $where .= " and type = 2";
if($type == 3) $where .= " and disabled = 1";
}
$KEY = $post['keywords'];