您的位置:首页 > 运维架构 > 网站架构

设置网站只能通过域名访问,不能通过IP访问

2012-03-26 17:21 447 查看
<html>
<head>
<script>
if   (location.href.indexOf( "http://127.0.0.1")==-1)   {
location.href= "about:blank ";
//   location.href= "Other ";
}
</script>
</head>
<body>

You  can visit by url.
</body>

</html>
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: