<!-- Begin // Original: freeware.de // Web Site: http://freeware.de // MSIE Fix by: Kurt Grigg (kurt.grigg@virgin.net) /* Visit our site at http://www.star28.com/ for more code * This notice must stay intact for use */
function xMoveHandler(evnt) { Xpos = evnt.pageX; Ypos = evnt.pageY; }
if (document.layers) { window.captureEvents(Event.MOUSEMOVE); } var yBase = 200; var xBase = 200; var yAmpl = 10; var yMax = 40; var step = .2; var ystep = .5; var currStep = 0; var tAmpl=1; var Xpos = 1; var Ypos = 1; var i = 0; var j = 0; if (document.all) { document.onmousemove = MoveHandler; } else if (document.layers) { window.onMouseMove = xMoveHandler; } function animateLogo() { if (document.all) { yBase = window.document.body.offsetHeight / 4; xBase = window.document.body.offsetWidth / 4; } else if (document.layers) { yBase = window.innerHeight / 4; xBase = window.innerWidth / 4; } if (document.all) { for (i = 0 ; i < starsDiv.all.length; i++) { starsDiv.all[i].style.top = Ypos + Math.cos((20*Math.sin(currStep/20))+i*70)*yBase*(Math.sin(10+currStep/10)+0.2)*Math.cos((currStep + i*25)/10); starsDiv.all[i].style.left = Xpos + Math.sin((20*Math.sin(currStep/20))+i*70)*xBase*(Math.sin(10+currStep/10)+0.2)*Math.cos((currStep + i*25)/10); } } else if (document.layers) { for (j = 0; j < 7; j++) { //7 is number of NS layers! var templayer="a" + j; document.layers[templayer].top = Ypos + Math.cos((20*Math.sin(currStep/20))+j*70)*yBase*(Math.sin(10+currStep/10)+0.2)*Math.cos((currStep + j*25)/10); document.layers[templayer].left =Xpos + Math.sin((20*Math.sin(currStep/20))+j*70)*xBase*(Math.sin(10+currStep/10)+0.2)*Math.cos((currStep + j*25)/10); } } currStep += step; setTimeout("animateLogo()", 10); } animateLogo(); // End --> </script>
ألوان تتبع الماوس 2
طريقة التركيب
انسخ هذا الكود و ضعه في منطقة HEAD
الكود:
<!-- Original: Kurt Grigg (kurt.grigg@virgin.net)) --> <!-- Web Site: http://website.lineone.net/~kurt.grigg/javascript -->
<!-- This script and many more are available free online at --> <!-- The JavaScript Source!! http://javascript.internet.com -->
<script language="JavaScript"> /* Visit our site at http://www.star28.com/ for more code * This notice must stay intact for use */ <!-- Begin function nMouse(evnt){ Ypos = evnt.pageY; Xpos = evnt.pageX; }
function iMouse() { Ypos = event.y+document.body.scrollTop; Xpos = event.x+document.body.scrollLeft; }
function Comet() { var yBase = (document.layers)?window.innerHeight/4:window.document.body.clientHeight/4; var xBase = (document.layers)?window.innerWidth/4:window.document.body.clientWidth/4; for (i = 0; i < 14; i++){ var randCol = Math.round(Math.random()*8); var layer = (document.layers)?document.layers['n'+i]:me[i].style; layer.top =Ypos + yBase*Math.cos((currStep+i*4)/12)*Math.cos(0.7+currStep/200); layer.left = Xpos + xBase*Math.sin((currStep+i*3)/10)*Math.sin(8.2+currStep/400); if (ns) layer.bgColor = Clrs[randCol]; else layer.background = Clrs[randCol]; } currStep += step; setTimeout("Comet()",10); }
ns = (document.layers)?1:0; Clrs = new Array('ff0000','00ff00','ffffff','ff00ff','ffa500','ffff00','00ff00','ffffff','ff00ff'); yBase = 0; xBase = 0; step = 3; currStep = 0; Ypos = 0; Xpos = 0; if (ns){ for (i = 0; i < 14; i++) document.write('<LAYER NAME="n'+i+'" LEFT=0 TOP=0 CLIP="0,0,'+i/4+','+i/4+'"></LAYER>'); window.captureEvents(Event.MOUSEMOVE); window.onMouseMove = nMouse; } else{ document.write('<div style="position:absolute;top:0;left:0"><div style="position:relative">'); for (i=0; i < 14; i++) {document.write('<div id="me" style="position:absolute;top:0;left:0;width:'+i/4+';height:'+i/4+';font-size:'+i/4+'"></div>');} document.write('</div></div>'); document.onmousemove = iMouse; } window.onload = Comet; // End --> </script>
/* Visit our site at http://www.star28.com/ for more code Cursor scroller script- By Dynamicdrive.com For full source, Terms of service, and 100s DTHML scripts */
//1) set message to display var scroller_msg='مرحباً بكم في دليل العرب الشامل' //2) set whether message should auto disappear after x seconds (0=perpetual). //Note that double clicking page will also dismiss message var dismissafter=0
function ietruebody(){ return (document.compatMode && document.compatMode!="BackCompat")? document.documentElement : document.body }
var initialvisible=0 if (document.all) document.write('<marquee direction="right" id="curscroll" style="position:absolute;width:150px;border:1px solid black;font-size:14px;background-color:white;visibility:hidden">'+scroller_msg+'</marquee>')
function followcursor(){ //move cursor function for IE
if (initialvisible==0){ curscroll.style.visibility="visible" initialvisible=1 }
function dismissmessage(){ curscroll.style.visibility="hidden" }
if (document.all){ document.onmousemove=followcursor document.ondblclick=dismissmessage if (dismissafter!=0) setTimeout("dismissmessage()",dismissafter*1000) }
if (document.layers) {window.captureEvents(Event.MOUSEMOVE);} var yBase = 200; var xBase = 200; var step = 1; var currStep = 0; var Xpos = 1; var Ypos = 1;
if (document.all) { function MoveHandler(){ Xpos = document.body.scrollLeft+event.x; Ypos = document.body.scrollTop+event.y; } document.onmousemove = MoveHandler; }
else if (document.layers) { function xMoveHandler(evnt){ Xpos = evnt.pageX; Ypos = evnt.pageY; } window.onMouseMove = xMoveHandler; }
function animateLogo() { if (document.all) { yBase = window.document.body.offsetHeight/6; xBase = window.document.body.offsetWidth/6; } else if (document.layers) { yBase = window.innerHeight/8; xBase = window.innerWidth/8; }
if (document.all) { for ( i = 0 ; i < starsDiv.all.length ; i++ ) { starsDiv.all[i].style.top = Ypos + yBase*Math.sin((currStep + i*4)/12)*Math.cos(400+currStep/200); starsDiv.all[i].style.left = Xpos + xBase*Math.sin((currStep + i*3)/10)*Math.sin(currStep/200); } }
// Visit our site at http://www.star28.com/ for more code <!--
function click() { if (event.button==2) { alert('لا تعيدها'); } } document.onmousedown=click // --> </script>
منع استخدام زر الماوس اليمين بدون رسالة
اضغط بزر الماوس اليمين في اي مكان
استخدم ctrl + A لتحديد الكود و ctrl + C للنسخ
طريقة التركيب
انسخ هذا الكود و ضعه في منطقة HEAD
الكود:
<script language=JavaScript>
// Visit our site at http://www.star28.com/ for more code <!--
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;}
منع استخدام زر الماوس اليمين للصور اضغط بزر الماوس اليمين على الصورة
طريقة التركيب
انسخ هذا الكود و ضعه في منطقة HEAD
الكود:
<script language="JavaScript1.2">
/* Disable right click script II (on images)- By Dynamicdrive.com For full source, Terms of service, and 100s DTHML scripts Visit http://www.dynamicdrive.com * Translated By www.star28.com/ */
var clickmessage="الزر اليمين لا يعمل على الصور "
function disableclick(e) { if (document.all) { if (event.button==2||event.button==3) { if (event.srcElement.tagName=="IMG"){ alert(clickmessage); return false; } } } else if (document.layers) { if (e.which == 3) { alert(clickmessage); return false; } } else if (document.getElementById){ if (e.which==3&&e.target.tagName=="IMG"){ alert(clickmessage) return false } } }
function associateimages(){ for(i=0;i<document.images.length;i++) document.images[i].onmousedown=disableclick; }
if (document.all) document.onmousedown=disableclick else if (document.getElementById) document.onmouseup=disableclick else if (document.layers) associateimages() </script>
كود يمنع استخدام الزر الايمن وايضا يمنع اي عمليه مسح لصورة او كتابة
/* Swirling cursor trail (By Ozone, http://ozone.com) Featured on JavaScript Kit free JavaScripts with bug fix for IE (http://javascriptkit.com) Visit our site at http://www.star28.com/ for more code */
window.onerror=null; netscape = (document.layers) ? 1:0; goodIE = (document.all) ? 1:0; document.onmousemove=MoveHandler; var gotthere = 0; var count = 0; var ietopcorner='' var ieleftcorner=''
toplocation = new Array( 0,30,57,80,101,125,80,80,101,125,80,0 ); temptoplocation = new Array( 50,100,100,150,150,200,200,100,150,150,200,200,0 ); leftlocation = new Array( 0,292,318,181,181,217,263,318,181,181,217,263,-96 ); templeftlocation = new Array( 0,0,260,390,420,550,680,390,420,550,680,0 ); difftop = new Array( 0,0,0,0,0,0,0,0,0,0,0,0 ); diffleft = new Array( 0,0,0,0,0,0,0,0,0,0,0,0 ); questtop = -13; questleft2 = -96; if (netscape) { document.body=new Object() document.body.scrollTop='' document.body.scrollLeft='' window.captureEvents(Event.MOUSEMOVE); window.onMouseMove = MoveHandler; var layerstart = "document."; var layerleft = ".left"; var layertop = ".top"; var layerstyle = ""; var windowWidth = window.innerWidth; var windowHeight = window.innerHeight; } else if (goodIE) { ietopcorner=document.body.scrollTop ieleftcorner=document.body.scrollLeft layerstart = "document.all."; layerleft = ".left"; layertop = ".top"; layerstyle = ".style"; windowWidth=600; windowHeight=400; } // end error trapping var Ypos2 = 72; var Xpos2 = 72; function MoveHandler(e) { if (netscape || goodIE) { Xpos2 = (netscape)?e.pageX:event.x Ypos2 = (netscape)?e.pageY:event.y Xorigin = Xpos2; Yorigin = Ypos2; if (Ypos2 > windowHeight/2) { if (Xpos2 > windowWidth/2) { direction = 1;} else { direction = -1;} } else { if (Xpos2 > windowWidth/2) { direction = -1;} else { direction = 1;} } }}
function startthedots() { if (goodIE) { windowWidth=document.body.clientWidth; windowHeight=document.body.clientHeight; } Xorigin = 204; Yorigin = 147; spin();run(); }
var OrbitSize = 200; count=1; delay=100; direction = -1; Count = new Array ( 0, .63, 1.26, 1.89, 2.52, 3.15, 3.78, 4.41, 5.04, 5.67 ); Xpoint = new Array ( 0, .63, 1.26, 1.89, 2.52, 3.15, 3.78, 4.41, 5.04, 5.67 ); Ypoint = new Array ( 0, .63, 1.26, 1.89, 2.52, 3.15, 3.78, 4.41, 5.04, 5.67 ); var speed = -0.06; var offset = 1;