Guest zethilone Posted July 24, 2003 Posted July 24, 2003 Here are some cool things to know! Just giving back to all of you! =========================================== No right click ><!-- goes in the head of ur document --> <script language=JavaScript> var message=""; /////////////////////////////////// function clickIE() {if (document.all) {(message);return false;}} function clickNS(e) {if (document.layers||(document.getElementById&&!document.all)) { if (e.which==2||e.which==3) {(message);return false;}}} if (document.layers) {document.captureEvents(Event.MOUSEDOWN);document.onmousedown=clickNS;} else{document.onmouseup=clickNS;document.oncontextmenu=clickIE;} </script> No right click with pop up message ><!-- this goes in the head of the document --> <script LANGUAGE="JavaScript" TYPE="text/javascript"> <!-- // block the right mouse click on the page var message="ur message here" function click(e) { //3.0 if (document.all) { if (event.button == 2 || event.button == 3 || event.button == 6 || event.button == 7) { alert(message); return false; } } if (document.layers) { if (e.which == 3) { alert(message); return false; } } } if (document.layers) { document.captureEvents(Event.MOUSEDOWN); } document.onmousedown=click; // --> </SCRIPT> Add to Favorite ><A href="javascript:window.external.AddFavorite('http://YourLink.com','Your WebPage Title')">add To Favourites</a> Set as Homepage ><A href="javascript:history.go(0)" onClick="javascript:this.style.behavior='url(#default#homepage)';this.setHomePage('http://www.YourLink.com');" TARGET="_self">Set As HomePage</A> </SCRIPT> Remove Link Underline ><Style TYPE="text/css"> <!-- A { text-decoration: none; } --> </Style> JavaScript Redirect ><script Language="JavaScript"> <!-- Begin if (navigator.javaEnabled()) window.location = "JavaEnabledPage.html"; else window.location = "JavaDisabledPage.html"; // End --> <!-- Redirect a browser depending on wether or not JavaScript is enabled. --> </Script> Browser Redirect ><!-- Redirect a browser depending on the version/OS. --> <script LANGUAGE="JavaScript"> <!-- function CheckBrowser(){ if((parseInt(navigator.appVersion) < 4 )){ window.location.href="InternetExplorer4OrLess.html" } else { if(navigator.platform == "MacPPC") { window.location.href="Macintosh.html" } else { if(navigator.platform == "Mac68k") { window.location.href="68kMacintosh.html" } else { if (navigator.appName == "Microsoft Internet Explorer") { window.location.href="InternetExplorer5OrGreater.html" }else { if(navigator.platform == "Win32") { window.location.href="Windows32Bit.html" } else { if(navigator.platform == "Win16") { window.location.href="Windows16.html" } else { window.location.href="Undefined.html" } } } } } } } // --> </SCRIPT> <Body OnLoad="CheckBrowser();"> Frames Removal ><!-- If your page is loaded in a frame, this will reload it in an entire window. --> <script Language="JavaScript"> <!-- Begin if (window != top) top.location.href = location.href; // End --> </Script> Redirection Type A ><!-- Will wait for 1 second, and redirect. Change to -1 to change as soon as page loads, or any other interval. --> <Meta Http-Equiv=Refresh Content="1;" URL="Redir.html"> Redirection Type B ><!-- Will redirect the browse upon execution. --> <script Language="JavaScript"> <!--Begin window.location.href="Some.html" // End --> </Script> History go back ><!-- Will send the browser back one page.Use 0 to reload the current page. --> <script Language="JavaScript"> <!-- Begin history.go(1) // End --> </Script> History Go Forward ><!-- Will send the browser forward one page.Use 0 to reload the current page. --> <script Language="JavaScript"> <!-- Begin history.go(-1) // End --> </Script> [edited by D. Scott Demmin; JavaScript Redirect vs. Java Redirect] Quote
Guest zethilone Posted July 24, 2003 Posted July 24, 2003 Disable Image Toolbar ><!-- goes in the head of ur document --> <META HTTP-EQUIV="imagetoolbar" CONTENT="no"> No select text ><!-- goes in the head of ur document --> <script language="JavaScript1.2"> function disableselect(e){ return false } function reEnable(){ return true } //if IE4+ document.onselectstart=new Function ("return false") //if NS6 if (window.sidebar){ document.onmousedown=disableselect document.onclick=reEnable } </script> Cross hair ><!-- goes in the head tag (note u can change the color of the cross hair by changing the "background - color" of the script to black or yellow or watever u want) --> <style> <!-- #leftright, #topdown{ position:absolute; left:0; top:0; width:1px; height:1px; layer-background-color:black; background-color:red; z-index:100; font-size:1px; } --></style> <div id="leftright" style="width:expression(document.body.clientWidth-2)"> </div> <div id="topdown" style="height:expression(document.body.clientHeight-2)"> </div> <script language="JavaScript1.2"> <!-- if (document.all&&!window.print){ leftright.style.width=document.body.clientWidth-2 topdown.style.height=document.body.clientHeight-2 } else if (document.layers){ document.leftright.clip.width=window.innerWidth document.leftright.clip.height=1 document.topdown.clip.width=1 document.topdown.clip.height=window.innerHeight } function followmouse1(){ //move cross engine for IE 4+ leftright.style.pixelTop=document.body.scrollTop+event.clientY+1 topdown.style.pixelTop=document.body.scrollTop if (event.clientX<document.body.clientWidth-2) topdown.style.pixelLeft=document.body.scrollLeft+event.clientX+1 else topdown.style.pixelLeft=document.body.clientWidth-2 } function followmouse2(e){ //move cross engine for NS 4+ document.leftright.top=e.y+1 document.topdown.top=pageYOffset document.topdown.left=e.x+1 } if (document.all) document.onmousemove=followmouse1 else if (document.layers){ window.captureEvents(Event.MOUSEMOVE) window.onmousemove=followmouse2 } function regenerate(){ window.location.reload() } function regenerate2(){ setTimeout("window.onresize=regenerate",400) } if ((document.all&&!window.print)||document.layers) //if the user is using IE 4 or NS 4, both NOT IE 5+ window.onload=regenerate2 //--> </script> Quote
Guest zethilone Posted July 24, 2003 Posted July 24, 2003 Message that comes toward the screen ><!-- this goes in the head --> <script LANGUAGE="JavaScript"><!-- Begin message = "ur message here"; colours = new Array('ff0000')//Pick your colors, any amount. siZe = 20;//Explorer only! can be outrageous size. message = message.split(' '); timer = null; clrPos = 0; msgPos = 0; jog = 1; currentStep = 10; step = 8; ns = (document.layers)?1:0; viz = (document.layers)?'hide':'hidden'; if (ns) document.write("<div id='T' style='position:absolute'></div><br>"); else { document.write("<div style='position:absolute'>"); document.write("<div align='center' style='position:relative'>"); document.write("<div id='T' style='position:absolute;width:0;height:0;font-family:Arial;font-size:0'>kurt</div>"); document.write("</div></div><br>"); } function Message() { var pageHeight = (document.layers)?window.innerHeight:window.document.body.offsetHeight; var pageWidth = (document.layers)?window.innerWidth:window.document.body.offsetWidth; if (ns) { ypos = pageHeight / 2; var Write = '<div align="center" style="width:0px;height:0px;font-family:Arial,Verdana;font-size:'+currentStep/4+'px;color:'+colours[clrPos]+'">'+message[msgPos]+'</div>'; document.T.top = ypos + -currentStep / 8 + window.pageYOffset; document.T.document.write(Write) document.T.document.close(); } else { ypos = pageHeight / 2; xpos = pageWidth / 2; T.style.width = currentStep; T.style.pixelTop = ypos + -currentStep / 16 + document.body.scrollTop; T.style.pixelLeft = (xpos - 20)+ -currentStep / 2; T.style.fontSize = currentStep / 8; T.innerHTML = message[msgPos]; T.style.color = colours[clrPos]; } if (ns)step += 5; else step += 15; currentStep += step if (ns) { if (currentStep > pageWidth) { currentStep = 10; step = 8; msgPos += jog; clrPos += jog; } if (clrPos >= colours.length) clrPos = 0; } else { if (currentStep > pageWidth * siZe) { currentStep = 10; step = 8; msgPos += jog; clrPos += jog; } if (clrPos >= colours.length) clrPos = 0; } if (msgPos >= message.length) { clearTimeout(timer); if (ns) document.T.visibility = viz; else T.style.visibility = viz; } timer = setTimeout("Message()",40) } // End --> </script> <body onLoad="Message()"> Pop up message from clicking a link ><!-- paste this in the head --> <script language="javascript"> <!-- hide javascript function showAlert () { alert ("Your pop up message here"); } // done hiding --> </SCRIPT> <A href="urpage.html" onClick="showAlert()"> Message scroll in browser status bar ><!-- paste in the head --> <script LANGUAGE="JavaScript"> <!-- Begin var Message="ur message here "; var place=1; function scrollIn() { window.status=Message.substring(0, place); if (place >= Message.length) { place=1; window.setTimeout("scrollOut()",300); } else { place++; window.setTimeout("scrollIn()",50); } } function scrollOut() { window.status=Message.substring(place, Message.length); if (place >= Message.length) { place=1; window.setTimeout("scrollIn()", 100); } else { place++; window.setTimeout("scrollOut()", 50); } } // End --> </SCRIPT> <body onLoad="scrollIn CSS Example ><!-- this makes ur link change color on mouseover and customises the color of ur visited and active links( paste in the head) --> <style type="text/css"> A:link {text-decoration:none;color:red} A:visited {text-decoration:none;color:yellow} A:active {text-decoration:none;color:blue} A:hover {color: blue;} // hover only works in ie </style> Quote
Guest zethilone Posted July 24, 2003 Posted July 24, 2003 CSS - Customise the Scroll bar color ><!-- paste this in ur head tag (u can change the color to watever u want it to b) --> <STYLE>BODY { SCROLLBAR-FACE-COLOR: red; SCROLLBAR-HIGHLIGHT-COLOR: gray; SCROLLBAR-SHADOW-COLOR: black; SCROLLBAR-ARROW-COLOR: gray; SCROLLBAR-TRACK-COLOR: black; SCROLLBAR-DARKSHADOW-COLOR: red } </STYLE> Confirm a continue ><script LANGUAGE="JavaScript"> <!-- Begin var agree=confirm("Would you like to continue?"); if (agree) document.write(""); else history.go(-1); // End --> </SCRIPT> Marquee on Web page ><script language="JavaScript1.2"> //Specify the marquee's width (in pixels) var marqueewidth=330 //Specify the marquee's height (in pixels, pertains only to NS) var marqueeheight=20 //Specify the marquee's scroll speed (larger is faster) var speed=6 //Specify the marquee contents var marqueecontents='<font face="Arial"><strong><big>Iran Hackers</Big></strong></font>' if (document.all) document.write('<marquee scrollAmount='+speed+' style="width:'+marqueewidth+'">'+marqueecontents+'</marquee>') function regenerate(){ window.location.reload() } function regenerate2(){ if (document.layers){ setTimeout("window.onresize=regenerate",450) intializemarquee() } } function intializemarquee(){ document.cmarquee01.document.cmarquee02.document.write ('<nobr>'+marqueecontents+'</nobr>') document.cmarquee01.document.cmarquee02.document.close() thelength=document.cmarquee01.document.cmarquee02.document.width scrollit() } function scrollit(){ if (document.cmarquee01.document.cmarquee02.left>=thelength*(-1)){ document.cmarquee01.document.cmarquee02.left-=speed setTimeout("scrollit()",100) } else{ document.cmarquee01.document.cmarquee02.left=marqueewidth scrollit() } } window.onload=regenerate2 </script> <ilayer width=&{marqueewidth}; height=&{marqueeheight}; name="cmarquee01"> <layer name="cmarquee02"></layer> </ilayer> Message that follows the mouse ><!-- paste this in the head --> <style type="text/css"> <!-- .spanstyle { position:absolute; visibility:visible; top:-50px; font-size:15pt; font-family:Verdana; font-weight:bold; color:#cc0000; } BODY { width:100%;overflow-x:hidden;overflow-y:scroll; } --> </style> <script language="JavaScript1.2"> <!-- var x,y var kern=20 var flag=0 var message="Inspirational Message Here" message=message.split("") var xpos=new Array() for (i=0;i<message.length;i++) { xpos[i]=-50 } var ypos=new Array() for (i=0;i<message.length;i++) { ypos[i]=-50 } function handlerMM(e){ x = (e) ? e.pageX : document.body.scrollLeft+event.clientX y = (e) ? e.pageY : document.body.scrollTop+event.clientY flag=1 } function makebanner() { if (flag==1) { for (i=message.length-1; i>=1; i--) { xpos[i]=xpos[i-1]+kern ypos[i]=ypos[i-1] } xpos[0]=x+kern ypos[0]=y for (i=0; i<message.length; i++) { if (document.getElementById) { var thisspan = document.getElementById("span"+i).style } else { var thisspan = eval((document.layers)?"document.span"+i:"span"+(i)+".style") } if (thisspan.posLeft) { thisspan.posLeft=xpos[i] thisspan.posTop=ypos[i] } if (!thisspan.posLeft) { thisspan.left=xpos[i] thisspan.top=ypos[i] } } } var timer=setTimeout("makebanner()",30) } window.onload=makebanner; //--> </script> <script language="JavaScript1.2"> <!-- for (i=0;i<message.length;i++) { document.write("<span id='span"+i+"' class='spanstyle'>") document.write(message[i]) document.write("</span>") } if (document.layers){ document.captureEvents(Event.MOUSEMOVE); } document.onmousemove = handlerMM; //--> </script> Quote
SEO Posted July 24, 2003 Posted July 24, 2003 I did not look at all the code... but nice collection! Thank you. Quote
Guest zethilone Posted July 24, 2003 Posted July 24, 2003 Adds a description to your status bar ><!-- paste this in ur body and customise the links --> <A HREF="http://www.iranhackers.net" onMouseOver="window.status='Iran Hackers';return true;" onmouseout="window.status='';return true">Iran Hackers</a> Quick navigation ><FORM name="QuickIndex" ><SELECT size=5 name="URL" onChange="if(options[selectedIndex].value) window.location.href= (options[selectedIndex].value)"> <OPTION value="ss01.html">page1</OPTION><OPTION value="ss02.html">page2</OPTION><OPTION value="ss03.html">page3</OPTION><OPTION value="ss04.html">page4</OPTION><OPTION value="ss05.html">page5</OPTION><OPTION value="ss06.html">etc</OPTION><OPTION value="ss07.html">7</OPTION><OPTION value="ss08.html">8</OPTION><OPTION value="ss09.html">9</OPTION></SELECT><NOSCRIPT><INPUT type=submit value="Go"> Measure how much time a visitor is on your page ><!-- paste this in the head --> <script LANGUAGE="JavaScript"> function person_in() { enter=new Date(); } function person_out() { exit=new Date(); time_dif=(exit.getTime()-enter.getTime())/1000; time_dif=Math.round(time_dif); alert ("You've only been here for: " + time_dif + " seconds!!") } </SCRIPT> Fake a virus infection from clicking a link -hehehehehe- ><!-- paste this in the head --> <script language="JavaScript"> <!-- function confirmClose() { alert("Error: 107x has occurred. A malicious virus has infected your system. Please refer to your anti-virus system for details.") if (confirm("Please close all running applications and repair this virus immediately.")) alert('The virus is using polymorphic abilities and hence your kernel 32 module will be infected.'); else alert('The virus cannot be repaired. Exit all applications and place the virus into quarantine to prevent interaction with your system files.'); { parent.close(); } } // End --> function MM_displayStatusMsg(msgStr) { //v1.0 status=msgStr; document.MM_returnValue = true; } function MM_popupMsg(msg) { //v1.0 alert(msg); } //--> </script> <div id="Layer8" style="position:absolute; width:200px; height:115px; z-index:8; left: 271px; top: 435px"> <p><font color="#ff0000">ur message here </font></p> <p align="center"> <input type="button" value ="ur choice here" onClick="confirmClose()" name="button"> CSS - Make a text or image or link blur ><!-- Scripts , www.iranhackers.net --> <font" style='FILTER: blur; COLOR: #ffffff; HEIGHT: 10px;'>Text</font> <img src='image' style='FILTER: blur; HEIGHT: 10px;'> DONE! Quote
Guest zethilone Posted July 24, 2003 Posted July 24, 2003 I did not look at the code... but nice collection! thanks :-) Quote
leezard Posted July 24, 2003 Posted July 24, 2003 holy cow thats a lot of code!! nice collection there Quote
borfast Posted July 25, 2003 Posted July 25, 2003 For those of you who want to try these scripts, note that most of them only work on Internet Explorer and are not standards compliant. Otherwise, great collection, Zethilone Quote
TCH-Sales Posted July 25, 2003 Posted July 25, 2003 wow, talk about a guy who did his homework! haha.. Good stuff all around! Quote
TCH-Don Posted July 25, 2003 Posted July 25, 2003 Wow is right, talk about giving back to the family! Thanks for all the work. Thumbs Up I have found that the disable image toolbar for IE6 <META HTTP-EQUIV="imagetoolbar" CONTENT="no"> will work anywhere in the page. Quote
Guest zethilone Posted July 26, 2003 Posted July 26, 2003 It is good to keep things organized. And thanks Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.