极客指定地区

This commit is contained in:
“wanyongkang”
2021-05-27 16:51:39 +08:00
parent 2ed3cd327e
commit ebd3822a08
2 changed files with 3 additions and 3 deletions

View File

@@ -29,7 +29,7 @@ class AccountAddress
} }
$url = 'http://city.webok.me/apichange/?user='.$account.'&password='.$password.'&type=edit&current_line_list='.$add_text.'&line_id_list='.$add_id; $url = 'http://city.webok.me/apichange/?user='.$account.'&password='.$password.'&type=edit&current_line_list='.$add_text.'&line_id_list='.$add_id;
$content = linkcurl($url,'GET'); $content = linkcurl($url,'GET',[],[],0);
echo $content; echo $content;
} }

View File

@@ -148,7 +148,7 @@ function realname($data){
* @param int $ipost [是否采用POST形式] * @param int $ipost [是否采用POST形式]
* @return string * @return string
*/ */
function linkcurl($url,$method,$params=[],$header=[]){ function linkcurl($url,$method,$params=[],$header=[],$header_show =1){
$httpInfo = array(); $httpInfo = array();
$ch = curl_init(); $ch = curl_init();
@@ -157,7 +157,7 @@ function linkcurl($url,$method,$params=[],$header=[]){
curl_setopt($ch, CURLOPT_HTTPHEADER, $header); curl_setopt($ch, CURLOPT_HTTPHEADER, $header);
curl_setopt($ch, CURLOPT_FAILONERROR, false); curl_setopt($ch, CURLOPT_FAILONERROR, false);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_HEADER, 1); //是否显示头信息 curl_setopt($ch, CURLOPT_HEADER, $header_show); //是否显示头信息
if (1 == strpos("$".$url, "https://")) if (1 == strpos("$".$url, "https://"))
{ {