这里太静了,发个自动选择镜像站代码
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>JGWY</title>
<style type="text/css">
<!--
body {
margin: 0;
padding: 0;
font-size: 14px;
color: #333;
text-align: center;
}
#wrap {
margin:50px auto;
background: #FFF;
}
#wrap p{
margin:40px 0;
}
a:link {
color: #63b900;
text-decoration: none;
border-bottom: 1px dashed;
}
a:visited {
color: #7fc937;
text-decoration: none;
border-bottom: 1px dashed;
}
a:hover {
color: #cc6600;
}
a:active {
color: #4f711f;
}
-->
</style></head>
<body>
<div id="wrap">
<p>尊敬的朋友,您好!正在为您自动选择最快的镜像服务器访问本站</p>
<p>速度测试中……</p>
<script type="text/javascript">
i=1
var autourl=new Array()
autourl="http://www.no-sky.com/index.php"
autourl="http://dx.no-sky.com/index.php"
autourl="http://wt.no-sky.com/index.php"
autourl="http://hk.no-sky.com/index.php"
autourl="http://mg.no-sky.com/index.php"
function auto(url){
if(i){i=0;top.location=url}
}
function run(){
for(var i=1;i<autourl.length;i++)
document.write("<img src='"+autourl+"' width=1 height=1 onerror=auto('"+autourl+"')>")
}
run()
</script>
<p>选择最快的镜像站点访问:</p>
<p><a href="http://www.no-sky.com/index.php">■移动主站</a> | <a href="http://dx.no-sky.com/index.php">■电信主站</a> | <a href="http://wt.no-sky.com/index.php">■网通主站</a> | <a href="http://hk.no-sky.com/index.php">■香港主站</a> | <a href="http://mg.no-sky.com/index.php">■美国主站</a></p>
</div>
</body>
</html> 兄弟 不要误人子弟function run是这样滴
function run(){
for(var i=1;i<autourl.length;i++)
document.write("<img src='"+autourl+"' width=1 height=1 onerror=auto('"+autourl+"')>")
} 原来是这鸟论坛给过滤掉了
function run(){
for(var i=1;i<autourl.length;i++)
document.write("<img src='"+autourl+"' width=1 height=1 onerror=auto('"+autourl+"')>")
}
晕,偶也是从别处抄来滴 这样没有任何意义,要能够自动测试镜像速度并选择速度最快的镜像才行
页:
[1]