帝国CMS新浪iplookup根据ip跳转到其他域名

$IP_str=file_get_contents('http://int.dpool.sina.com.cn/iplookup/iplookup.php');
$IP_tmp = explode("/n", $IP_str);
$IPcou=count($IP_tmp)-1;
$IP_tmp1 = explode("        ", $IP_tmp[0]);
if($IP_tmp1[5]){
        $user_IP=$IP_tmp1[5];         
}else{
        $user_IP=$IP_tmp1[4];                 
}//开源软件:Cuoxin.com
if($user_IP == '上海'){
   header('Location: A.php');
}elseif($user_IP == '北京'){
   header('Location: B.php');
}else{
   header('Location: C.php');
}
 

dawei

【声明】:郑州站长网内容转载自互联网,其相关言论仅代表作者个人观点绝非权威,不代表本站立场。如您发现内容存在版权问题,请提交相关链接至邮箱:bqsm@foxmail.com,我们将及时予以处理。