Disable ctrl+c,ctrl+u and right click

Disable in the whole document from copy,ctrl+u and right click.

<!-- Disable ctrl+u & ctrl+c and prevent Right Click --> 

<script  type="text/javascript" src="http://ajax.microsoft.com/ajax/jquery/jquery-1.4.2.min.js"></script>

<script type="text/javascript">
$(document).ready(function()
{
    $(document).bind("contextmenu",function(e)
    {
       return false;
    });
});
</script>

<script type="text/javascript">
var isCtrl = false;
document.onkeyup=function(e)
{
   if(e.which == 17)
     isCtrl=false;
}
document.onkeydown=function(e)
{
   if(e.which == 17)
      isCtrl=true;
   if((e.which == 85) || (e.which == 67) && isCtrl == true)
   {
      return false;
   }
}
</script>

<!-- disable ctrl+u & ctrl+c and prevent Right Click -->
Please follow and like us:
0