<?php
$token = "e923196639594aa9e1f463225bc8e5d4";
$domain = "www.qq.com";
$url = sprintf("https://www.5la.cn/api/wxdomain.html?domain=%s&token=%s", $domain, $token);
$curl = curl_init();
curl_setopt($curl, CURLOPT_URL, $url);
curl_setopt($curl, CURLOPT_HEADER, 0);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($curl, CURLOPT_ENCODING, '');
curl_setopt($curl, CURLOPT_USERAGENT, $UserAgent);
curl_setopt($curl, CURLOPT_FOLLOWLOCATION, 1);
$data = curl_exec($curl);
$res = json_decode($data, true);
if($res['code']==200){
echo "域名正常";
}else{
echo $res['msg'];
}代码里的token是我自己申请的,有需要的同学可以自己申请替换
wxdomaincheck.zip
( 78.7 KB 下载:19 次 )
