while browsing i saw this website, https://deavita.com/lifestyle/haustiere/wellensittiche-halten-artgerecht-vogel-kaefig-voliere.html checked a post and wanted to download the image. when right click on image, it gave me two option. 1) embed the image 2) or signup so my question is how can i add such same functoin in my website. and is that a plugin or something else? if plugin, plz tell the name of plugin, i try to detect plguin but non of them have such thing.
Asked
Active
Viewed 16 times
1 Answers
1
This behavior is handled by javascript. you can find out if the user has fired a mouse click event on an element and check if it is a right-click or left-click, then call the desired function. It is also possible to change the browser's default context menu when right-clicking on an element. For more details check this answer https://stackoverflow.com/a/2405835/2991891

Reza
- 1,065
- 1
- 10
- 18