Purushottam Rathore

Purushottam Rathore

  • 216
  • 8.7k
  • 8.8m

How to disable mouse left click on the page.

Apr 28 2009 2:16 AM

Hi

Can anybody help me to disable mouse left click on the page. actually i want to disable mouse left click, so that any body can't copy any content from my site.

Here i am using following code.

<script language="javascript">
function
noLeftClick()
{
if (event.button==1)
{
//alert('Not allowed')
a;
}
}
document.onmousedown=noLeftClick
</script>

This is fine, But how to disable Ctrl+A to select the content.


Answers (5)