php 批量查询搜狗sogou代码分享 php 批量查询搜狗sogou代码分享

软件发布|下载排行|最新软件

当前位置:首页IT学院IT技术

php 批量查询搜狗sogou代码分享 php 批量查询搜狗sogou代码分享

  2021-03-21 我要评论
想了解php 批量查询搜狗sogou代码讲解的相关内容吗,在本文为您仔细讲解php 批量查询搜狗sogou代码讲解的相关知识和一些Code实例,欢迎阅读和指正,我们先划重点:php,file_get_contents,下面大家一起来学习吧。

php 批量查询搜狗sogou的rank,非常不错,主要是使用了php的file_get_contents()方法。

<?php
date_default_timezone_set('Asia/Shanghai');
header('Content-Type: text/html; charset=utf-8');
 
@$txt = file_get_contents("list.txt" );
$arr = explode("\r\n" , trim($txt));
 
if(count($txtarr)<0){
  exit('no site');
}
 
foreach($arr as $v){
  $sr=file_get_contents("http://rank.ie.sogou.com/sogourank.php?ur=http%3A%2F%2F{$v}%2F");
  $sr=str_replace('sogourank=','',$sr);
  if($sr>2){
    echo $v."<br />\n";
  }else{
    continue;  
  }
}

以上所述就是本文的全部内容了,希望大家能够喜欢。

Copyright 2022 版权所有 软件发布 访问手机版

声明:所有软件和文章来自软件开发商或者作者 如有异议 请与本站联系 联系我们