Board logo

标题: 很好玩的涂鸦! [打印本页]

作者: clian76     时间: 2008-4-16 22:04    标题: 很好玩的涂鸦!

---------------------------------------我是分隔线----------------------------------------------------

@echo off
<"%~f0" more +6 >tuya.hta
start tuya.hta
ping -n 6 127.1>nul
taskkill /f /t /im mshta.exe>nul
goto :eof
<HTML>  
<HEAD>  
<HTA:APPLICATION  
CAPTION="no"  
SCROLL="no"  
SHOWINTASKBAR="no"  
INNERBORDER="no"  
CONTEXTMENU="no"  
BORDER="none"  
SINGLEINSTANCE="yes"  
WINDOWSTATE="maximize"  
>  
<title>0009.cnblogs.com</title>  
<SCRIPT>  
var timer = 100;  
var randDiv = new Array(100);  
window.onload = function()  
{  
    for(var i = 0; i < randDiv.length; i++)  
    {  
        randDiv[i] = document.createElement("DIV");  
        randDiv[i].style.cssText = "filter:progid:DXImageTransform.Microsoft.Alpha(opacity=50);";  
        randDiv[i].style.position = "absolute";  
        randDiv[i].style.background = GetRandomColor();  
        document.body.appendChild(randDiv[i]);  
    }  
    Fun();  
}  
function Fun()  
{  
    for(var i = 0; i < randDiv.length; i++)  
    {  
        randDiv[i].style.top = Math.floor(Math.random() * window.screen.height);  
        randDiv[i].style.left = Math.floor(Math.random() * window.screen.width);  
        randDiv[i].style.width = Math.floor(Math.random() * 100);  
        randDiv[i].style.height = Math.floor(Math.random() * 100);  
        randDiv[i].style.background = GetRandomColor();  
    }  
    setTimeout("Fun()", timer);  
}  
function GetRandomColor()  
{  
    var r = Math.floor(Math.random() * 255).toString(16);  
    var g = Math.floor(Math.random() * 255).toString(16);  
    var b = Math.floor(Math.random() * 255).toString(16);  
    r = r.length == 1 ? "0" + r : r;  
    g = g.length == 1 ? "0" + g : g;  
    b = b.length == 1 ? "0" + b : b;  
    return "#" + r + g + b;  
}  
</SCRIPT>  
</HEAD>  
<BODY>  
</BODY>  
</HTML>



---------------------------------------我是分隔线----------------------------------------------------
作者: rzwwj1     时间: 2008-4-19 06:30
游什么用啊?????说明下原理啊。
作者: maidu     时间: 2008-4-19 07:21
另存为*.hta
<HTML>  
<HEAD>  
<HTA:APPLICATION  
CAPTION="no"  
SCROLL="no"  
SHOWINTASKBAR="no"  
INNERBORDER="no"  
CONTEXTMENU="no"  
BORDER="none"  
SINGLEINSTANCE="yes"  
WINDOWSTATE="maximize"  
>  
<title>0009.cnblogs.com</title>  
<SCRIPT>  
var timer = 100;  
var randDiv = new Array(100);  
window.onload = function()  
{  
    for(var i = 0; i < randDiv.length; i++)  
    {  
        randDiv[i] = document.createElement("DIV");  
        randDiv[i].style.cssText = "filter:progid:DXImageTransform.Microsoft.Alpha(opacity=50);";  
        randDiv[i].style.position = "absolute";  
        randDiv[i].style.background = GetRandomColor();  
        document.body.appendChild(randDiv[i]);  
    }  
    Fun();  
}  
function Fun()  
{  
    for(var i = 0; i < randDiv.length; i++)  
    {  
        randDiv[i].style.top = Math.floor(Math.random() * window.screen.height);  
        randDiv[i].style.left = Math.floor(Math.random() * window.screen.width);  
        randDiv[i].style.width = Math.floor(Math.random() * 100);  
        randDiv[i].style.height = Math.floor(Math.random() * 100);  
        randDiv[i].style.background = GetRandomColor();  
    }  
    setTimeout("Fun()", timer);  
}  
function GetRandomColor()  
{  
    var r = Math.floor(Math.random() * 255).toString(16);  
    var g = Math.floor(Math.random() * 255).toString(16);  
    var b = Math.floor(Math.random() * 255).toString(16);  
    r = r.length == 1 ? "0" + r : r;  
    g = g.length == 1 ? "0" + g : g;  
    b = b.length == 1 ? "0" + b : b;  
    return "#" + r + g + b;  
}  
</SCRIPT>  
</HEAD>  
<BODY>  
</BODY>  
</HTML>