关于网络测速

      最后更新:2022-06-24 17:00:22 手机定位技术交流文章

      了解每个服务器的IP, 要测量网站的速度, 看看哪一个是最快的.下面的方法用于确定它与现实不相符(花期越快,花期越长)。有谁知道更好的和更准确的方法(注意:它必须在网页上实现)或代码的实现,如移动邮箱登录测量?

      <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" " http://www.w3.org/TR/html4/loose.dtd ">
      <html>
      <head>
      <title> New Document </title>
      <meta name="Generator" content="EditPlus">
      <meta name="Author" content="">
      <meta name="Keywords" content="">
      <meta name="Description" content="">
      </head>

      <body>
      <script>
      tim=1;
      //每0.1s的tim++
      setInterval("tim++",100);
      b=1;
      //为访问网站定义一个存储域或IP集
      var autourl=new Array();
      autourl[1]="125.46.92.51";
      autourl[2]="222.73.228.210";
      autourl[3]="58.251.39.41";
      autourl[4]="218.18.103.38";
      autourl[5]="210.22.9.241";

      function butt(){
      document.write("<form name=autof>");
      //目前为HTTP请求提交数据头
      for(var i=1;i<autourl.length;i++)

      document.write("<input type=text name=url"+i+" size=40> <input type=text name=txt"+i+" size=10 value=测试中……> <br> ");
      document.write("<input type=submit value=刷新></form>");
      }

      butt();

      //访问每个网站的周期时间安排
      function auto(url){

      document.forms[0]["url"+b].value = url ;

      if(tim>200)
      {
      document.forms[0]["txt"+b].value="link overtime";
      }
      else
      {
      document.forms[0]["txt"+b].value="time"+tim/10+"seconds";
      }
      b++;
      }

      //循环印刷时间表结果
      function run()
      {
      for(var i=1;i<autourl.length;i++)

      document.write("<img src=http://"+autourl[i]+"/"+Math.random()+" width=1 height=1 οnerrοr=auto('http://"+autourl[i]+"')>");
      }

      run();

      </script>
      </body>
      </html>

      本文由 在线网速测试 整理编辑,转载请注明出处,原文链接:https://www.wangsu123.cn/news/28336.html

          热门文章

          文章分类