UCloud海外节点vps活动:香港、台湾等全球14个机房1折起,最低仅150元/年
![]() | ![]() | ![]() | ![]() |
| 【性价之王】 | 【线路之王】 | 【价格之王】 | 【配置之王】 |
| 【免费之王】 | 【香港首推】 | 【梯子之王】 | 【独服之王】 |

首先如何获取必应的api密钥
直接上代码,复制保存为post.php,然后通过宝塔面板的计划任务添加即可。
<?php$arr = array( 'https://www.esphp.com.com' => array( 'url' => array( "https://www.esphp.com/sitemap.xml" ), 'bing_key' => "303c2be9581c432da0f65c6b2fa1b416" ),);foreach ($arr as $i => $j) { //网站地址 $website = $i; //站点地图 $url = $j['url']; //必应key $bing_key = $j['bing_key']; //配额接口调用地址 $quota_api = "https://ssl.bing.com/webmaster/api.svc/json/GetUrlSubmissionQuota?siteUrl=$website&apikey=$bing_key"; //URL提交API接口调用地址 $seturl_api = "https://ssl.bing.com/webmaster/api.svc/json/SubmitUrlBatch?apikey=$bing_key"; $s = file_get_contents($quota_api); $s = json_decode($s, true); echo "$website 必应今日剩余配额:".$s['d']['DailyQuota']." 本月剩余配额:".$s['d']['MonthlyQuota'];echo '<br>'; if($s['d']['DailyQuota']){ $ch = curl_init(); //防https错误 $xmlresponse = curl_exec($ch); $xml=simplexml_load_string($xmlresponse); $urls = array(); foreach ($url as $key => $value) { curl_setopt($ch, CURLOPT_URL, $value); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $xmlresponse = curl_exec($ch); $xml=simplexml_load_string($xmlresponse); foreach ($xml as $key => $value) { $urls[] = $value->loc; } } shuffle($urls); //必应api提交每次上限100条 if ($s['d']['DailyQuota']>=100) { $max = 100; } else { $max = $s['d']['DailyQuota']; } $urls = array_slice($urls, 0,$s['d']['DailyQuota']); if(!$urls){ echo $website.' 今日配额已全部提交!';continue; } $url_data = array_chunk($urls, $max, true); foreach ($url_data as $key => $value) { $url_str = implode(',',$value); $url_arr = explode(',',$url_str); $data = array( "siteUrl"=>$website, "urlList"=>$url_arr ); $ch = curl_init(); $options = array( CURLOPT_URL => $seturl_api, CURLOPT_POST => true, CURLOPT_RETURNTRANSFER => true, CURLOPT_POSTFIELDS => json_encode($data), CURLOPT_HTTPHEADER => array('Content-Type: application/json'), ); curl_setopt_array($ch, $options); $result = curl_exec($ch); echo "$website 必应提交信息:".$result;echo '<br>'; } }}?>将必应提供的key和站点地图修改为自己的即可
[主机测评]历史优惠活动内容
猜你可能想看的VPS
- 阿里云服务器 2020 年 2 月促销,100%CPU 性能,2 核 4全球[VPS测评]
- 云上互联→20.8 元 月 512MB 内存 35GB 空间 不限流量 虚拟空间(主机)
- 劳动节 搬瓦工→新增 10Gbps 带宽的 cn2 gia 线路 VPS全球[VPS测评]
- CloudCone→$15 年 KVM-512MB 10GB 1TB 洛全球[VPS测评]
- $14 年 256M 内存 10G SSD 1T 流量 1Gbps KV全球[VPS测评]
- 日本 VPS 8 美元每月 512M 内存 20G ssd 10T 流量日本VPS[主机]
- 便宜 $15 年 2 核 CPU 2G 内存 50G SSD 5T 流量全球[VPS测评]
- 测评 HostMem→1G 内存套餐测评数据 电信回程走 CN2 GIA全球[VPS测评]
- onevps 推出日本专业奈飞(Netflix)VPS 首月半价 10T日本VPS[主机]
- PHP 随机生成 N 个汉字 PHP 随机生成一段汉字全球[VPS测评]
- 便宜 $12.94 年 512M 内存 10G SSD 1T 流量@1G全球[VPS测评]
- vpsplayer 七五折特惠套餐,深圳BGP 折后¥66/月;香港CN香港VPS[主机]
- 搬瓦工VPS CN2方案和CN2 GIA-E 方案的选购建议全球[VPS测评]
- 咕咕云 → 1500元 年 苏日IPLC 1C2GB20GB硬盘 1T流独立服务器[U]
- Nusahost-4.67$月付 印尼 Windows系统VPS 1核2WINDOWS
- 50KVM VPS免费自助换IP功能全球[VPS测评]
- 什么是Bootstrap?全球[VPS测评]
- 日主机,便宜美国CN2高防VPS¥19/月起,1Gbps带宽,香港多IP站群服务器[IP]
- Mysql连接数过高,如何检查?全球[VPS测评]
- 二三互联,香港cn2云服务器5折+85折双重优惠,稳定不限流量,1核1G香港VPS[主机]
- 亿恩科技香港云服务器 2核2G服务器特价700元/年香港VPS[主机]
- 适合美容院的正能量抖音文案,唯美阳光,正能量满满全球[VPS测评]
- 阿里云香港服务器多少钱一年?阿里云香港云服务器如何购买?香港VPS[主机]
- UCloud海外云服务器促销:全场1折起,香港cn2vps最低年付150香港VPS[主机]
- GreenCloudVPS:6折优惠,日本、新加坡、香港等KVM VPS日本VPS[主机]
- UCloud海外节点vps活动:香港、台湾等全球14个机房1折起,最低仅香港VPS[主机]
- 酷锐云:香港安畅机房4H/4G/60G/20Mbps,45元/月;香港C香港VPS[主机]
- 野草云怎么样?香港、美国圣何塞高防VPS 1核1G3M 月付19元美国VPS[主机]
- 咖啡主机怎么样?咖啡香港/美国/法国VPS主机价格及配置推荐美国VPS[主机]
- 40火伞高压电爬坡更让企业用电于民全球[VPS测评]
转载请注明原文地址:http://140.238.13.167:12355/read-241931.html











