dhdh •!¦[• مسلم نشـيـط •]¦!•
عدد الرسائل : 68 العمر : 35 الإقـامـة : k.s.a المزاج : CoOoL المهـنه : طالب المـزاج : تاريخ التسجيل : 03/02/2008
| موضوع: كود مانع الزر الايمن فقط على الصور الخميس فبراير 07, 2008 11:07 am | |
| السلام عليكم اقدم لكم كود مانع استخدام زر الفاره بالزر الايمن ع الصور حفاظا على حقوق الموقع و تفضلوا الكود : - الكود:
-
<body> <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 [url=http://www.dynamicdrive.com/]http://www.dynamicdrive.com[/url] //المزيد والجديد من أكواد الجافا دوما ً على موقع المركز العربي للدعم الفني [url=http://soft.ihsac.com/]http://soft.ihsac.com[/url] */ 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> <body> | |
|