Solution 1 :

you will need to look into Element: contextmenu event, you will add event listener and you will disable all elemenr.

for the full details about this you could check Mozilla MDN Here

Problem :

An iframe is used to display PDF file. Need to disable right click on Iframe and PDF.


Comment posted by Kevin

Please supply starting code so that we may assist you in solving programmatic, logic and other such issues.

Comment posted by tnkarthick

I am using this code.

Comment posted by tnkarthick

“` “` Tried this. But Still I can able to see saves on right click context menu

Comment posted by tnkarthick

I tried this it works only on html document. it not works on iframe with PDF document.

Comment posted by arjun sah

@tnkarthick did you already solved this problem. If yes then please share your experience. I am also facing the same problem.

Comment posted by Midz Elwekil

do you want to not allow the user to save the document?