Sunday, June 24, 2012

Javascript disable right click


<script type="text/javascript">

function md(e)
{
  try { if (event.button==2||event.button==3) return false; }
  catch (e) { if (e.which == 3) return false; }
}
document.oncontextmenu = function() { return false; }
document.ondragstart   = function() { return false; }
document.onmousedown   = md;

</script>

safsdfsfsdfsdfsdafsdfsadf

No comments:

Post a Comment

Please mention your comments.......