Disabling copying of the survey and right click functions? | XM Community
Skip to main content
Solved

Disabling copying of the survey and right click functions?

  • April 20, 2018
  • 9 replies
  • 749 views

Hello, I am looking for how to disable the copying of the survey (including right click function) and the custom coding needed to accomplish this.

Best answer by TomG

There really isn't any way to stop someone from copying or doing screenshots of a survey. Therefore, disabling the contextmenu (right click) will, at most, only slow someone down a bit. You're fooling yourself if you think it will add any type of security. However, if you want to go through the useless exercise, you can disable the contextmenu by adding the following to an Qualtrics.SurveyEngine.addOnload function in the header of your survey: ``` jQuery(document).on("contextmenu", function(e){ e.preventDefault(); }, false); ```

9 replies

TomG
Level 8 ●●●●●●●●
Forum|alt.badge.img+27
  • Level 8 ●●●●●●●●
  • 6083 replies
  • Answer
  • April 20, 2018
There really isn't any way to stop someone from copying or doing screenshots of a survey. Therefore, disabling the contextmenu (right click) will, at most, only slow someone down a bit. You're fooling yourself if you think it will add any type of security. However, if you want to go through the useless exercise, you can disable the contextmenu by adding the following to an Qualtrics.SurveyEngine.addOnload function in the header of your survey: ``` jQuery(document).on("contextmenu", function(e){ e.preventDefault(); }, false); ```

  • Author
  • 1 reply
  • April 23, 2018
Thank you, TomG. This has been helpful. I recognize this adds essentially no protection, but for whatever reason it is required by the original owner of a measure that I am licensed to use. I appreciate your time.

Forum|alt.badge.img+1
Sorry, I am trying to do this but not really getting there. Is this the path? _Look & Feel > Advanced > Header _> what then?? Sorry, I am a beginner with Qualtrics. Thank you very much.

TomG
Level 8 ●●●●●●●●
Forum|alt.badge.img+27
  • Level 8 ●●●●●●●●
  • 6083 replies
  • June 27, 2018
Click on the question’s cog and Add JavaScript, then add to addOnload function.

Forum|alt.badge.img+1
Many thanks! It worked perfectly!

PeeyushBansal
Level 6 ●●●●●●
Forum|alt.badge.img+43
  • Level 6 ●●●●●●
  • 1169 replies
  • August 26, 2019
> @TomG said: > There really isn't any way to stop someone from copying or doing screenshots of a survey. Therefore, disabling the contextmenu (right click) will, at most, only slow someone down a bit. You're fooling yourself if you think it will add any type of security. > > However, if you want to go through the useless exercise, you can disable the contextmenu by adding the following to an Qualtrics.SurveyEngine.addOnload function in the header of your survey: > ``` > jQuery(document).on("contextmenu", function(e){ > e.preventDefault(); > }, false); > ``` Hi Tom, Just checking is there a way we can disable print screen in case we have images in survey.

TomG
Level 8 ●●●●●●●●
Forum|alt.badge.img+27
  • Level 8 ●●●●●●●●
  • 6083 replies
  • August 26, 2019
> @bansalpeeyush29 said: > Hi Tom, > Just checking is there a way we can disable print screen in case we have images in survey. I don't think there are any solutions that a determined respondent can't get around rather easily. See this post for a solution that may deter casual (i.e., not very determined) respondents: https://stackoverflow.com/a/37604125/4434072

PeeyushBansal
Level 6 ●●●●●●
Forum|alt.badge.img+43
  • Level 6 ●●●●●●
  • 1169 replies
  • August 27, 2019
Thanks Tom.

GrayMatterThinking
Level 2 ●●
Forum|alt.badge.img+4
I can't tell you how many times I have been asked to do this over the course of my working life and I am in full agreement with Tom. This is a futile exercise. You can always get around such 'protections' with minimal effort. They simply give an illusion of security. Doesn't stop people asking, doesn't stop me shaking my head and saying "but...", ultimately doesn't stop me pointlessly applying this anyway. Certainly not a dig at the OP - just recognition that basic technical literacy in this regard is lacking.