check if someone right click javascript
el.addEventListener('contextmenu', function(ev) {
ev.preventDefault();
alert('success!');
return false;
}, false);document.body.onclick = function (e) {
var isRightMB;
e = e || window.event;
if ("which" in e) // Gecko (Firefox), WebKit (Safari/Chrome) & Opera
isRightMB = e.which == 3;
else if ("button" in e) // IE, Opera
isRightMB = e.button == 2;
alert("Right mouse button " + (isRightMB ? "" : " was not") + "clicked!");
}
Also in PHP:
- array_column in php
- count rows mysql limit php
- add one day in date php
- date format in day name of month and year in php
- Laravel store multiple files
- check char inside string php
- display_errors php.ini
- PHP echo and print Statements
- difference entre deux date php
- Word Not Found!strpos(): needle is not a string or an integer on line 6
- codeigniter get last insert
- echo foreach
- Modularizing laravel 8.0
- datetime format laravel
- codeigniter get insert iditer print last query
- check array in array key
- date funciton
- PHP Startup: Unable to load dynamic library 'curl'
- To add a new Top-level menu to WordPress Administration, use the add_menu_page() function.
- echo php dropdown from db and save it in a db
- check my version of composer
- add console script in phpcode
- exception php
- daye in php