============================================================ Script: Basic No-Right-Click Script Functions: Blocks right-click on mouse and shows alert box Browsers: NS & IE 4.0 & later; degrades gracefully Author: etLux ============================================================ Put the following script in the head of your page: <script language="Javascript1.2"> // (C) 2003 CodeLifter.com // Source: CodeLifter.com // Do not remove this header // Set the message for the alert box am = "This function is disabled!"; // do not edit below this line // =========================== bV = parseInt(navigator.appVersion) bNS = navigator.appName=="Netscape" bIE = navigator.appName=="Microsoft Internet Explorer" function nrc(e) { if (bNS && e.which > 1){ alert(am) return false } else if (bIE && (event.button >1)) { alert(am) return false; } } document.onmousedown = nrc; if (document.layers) window.captureEvents(Event.MOUSEDOWN); if (bNS && bV<5) window.onmousedown = nrc; </script>
Khamis, Ogos 08, 2013
JavaScript : No right click
Label:
JavaScript,
web
Langgan:
Catat Ulasan (Atom)
0 ulasan:
Catat Ulasan
Selamat datang ke 0x2013LΣΣT. Sekiranya anda mempunyai persoalan, pandangan, permintaan, bantuan, cadangan dan sebagainya. Tinggalkan pesanan anda ke dalam kotak komen. Terima kasih !
- http://0x2013.blogspot.com -