js屏蔽地區訪問
<!---->
<script language='javascript' type='text/javascript' src='http://pv.sohu.com/cityjson'></script>
<script language='javascript' type='text/javascript'>
var city = returnCitySN['cname'];
var tc=1;
if(city.indexOf('北京') != -1 || city.indexOf('上海') != -1 || city.indexOf('深圳') != -1 || city.indexOf('廣州') != -1|| city.indexOf('江蘇') != -1|| city.indexOf('江西') != -1) {
bsgs=1;
window.location.href = "http://locahost:6666"
} else {
bsgs=0;
}
if(t == 'test') {
bsgs=0;
}
</script>
屏蔽PC端訪問
<!-- <script type="text/javascript">
//平臺、設備和操作系統
var system ={
win : false,
mac : false,
xll : false
};
//檢測平臺
var p = navigator.platform;
system.win = p.indexOf("Win") == 0;
system.mac = p.indexOf("Mac") == 0;
system.x11 = (p == "X11") || (p.indexOf("Linux") == 0);
if(system.win||system.mac||system.xll){
window.location.;
}else{
}
</script>