Follow Dashboard
Tokens?
TITLE; Tutorial Disable Dragging Images and Disable Rightclick
08 November 2011 | 3:52 AM | 3 comments
Hello guys,
today eeda nak buat tuto disable dragging image, taw ape maksudnye? haa, maksudnye, korang cuba tengok kat sidebar eeda nih and drag gambar to a new tab, tak boleh kan? haa, tu la yg eeda maksudkan. tuto nih di request oleh Fatihah .


1st skali, pegi Dashboard > Design > Edit HTML

Lepastu awak tekan Ctrl+F, cari

<head>

dah jumpa? okay copy code kat bawah ni, 
and paste kat bawah code tadi,

<SCRIPT TYPE="text/javascript">
<!--
//Disable right click script
//visit http://www.rainbow.arch.scriptmania.com/scripts/
var message="Sorry, right-click has been disabled";
///////////////////////////////////
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;}
document.oncontextmenu=new Function("return false")
// -->
</SCRIPT>



<script type="text/javascript">
document.ondragstart = function () { return false; }; </script>

Okay lepastu Save Template ye, pastu usya la blog korang. tadaa, padan muka takleh copy orang punya lagi. HAHA


Ohmaigoshhh, i miss my hubby so much ;(

Labels:



Old things | New things