//Disable mouse right click
$("body").on("contextmenu", function(e) {
return false;
});
<html>
<head>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
</head>
<body>
<h3>How to Disable Right Click using jQuery</h3>
<script>
$(document).ready(function(){
$(document).bind("contextmenu",function(e){
alert('right click disabled');
return false;
});
});
</script>
</body>
</html>
<script type="text/javascript">
$(document).ready(function () {
//to disable the entire page
$("body").on("contextmenu",function(e){
return false;
});
//to disable a section
$("#id").on("contextmenu",function(e){
return false;
});
});
</script>