打印

[转帖] hta实现涂鸦效果

hta实现涂鸦效果

hta:HTML Applications  
hta是html的可执行程序,制作很简单,将文件*.htm改为*.hta就可以了。
不过hta有自己独有的标签<hta>,并可设置其属性达到很不错的效果。
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>
该文章转载自脚本之家:http://www.jb51.net/html/200703/110/9014.htm
这是一个例子 保存到txt里然后把后缀名改为.hta即可

TOP

郁闷,没意思,超无聊的东西。
魔秋不出,谁与争疯~~~~~~
我帮你顶一下
这里还有一个http://bbs.hackerxfiles.net/view ... omuid=184#pid234993
有空去看看吧
————————————————————END—————————————————

TOP

呵呵    是很无聊啊~    麻烦LZ下次发个有创意的东西上来
嘎嘎~无意在网上看到的~就发过来了~不要见怪啦~

TOP

Processed in 0.044301 second(s), 5 queries, Gzip enabled