Avoid pasting answers | XM Community
Skip to main content

Hi! I’m very inexperienced with qualtrics and I could use some help with a specific point: 

I want to make a manipulation by asking participants to write a paragraph in the text entry type of question. However, I’m afraid they might use chatGPT to produce the text and fail my manipulation. Therefore, how do I create and insert a code that makes it not possible for people to copy & paste texts in their responses? 

 

I saw someone else here using the following code on JS, but it didn’t work for me: 

jQuery("#"+this.questionId+" .InputText:eq(0)").on("cut copy paste",function(e) {
   e.preventDefault();
  });

 

This is the link to where they mentioned this code: 

 

Thank you! 

The code is correct and should work as it is working for me, please make sure it placed at the right place.


The code is correct and should work as it is working for me, please make sure it placed at the right place.

Hi, Shashi! 

Could you help me understand where I should put it? It is not working for me. When I do the preview I can still paste texts on the text entry. Bellow, there’s a screenshot of what I did: 

Thanks


The code is correct and should work as it is working for me, please make sure it placed at the right place.

Hi, Shashi! 

Could you help me understand where I should put it? It is not working for me. When I do the preview I can still paste texts on the text entry. Bellow, there’s a screenshot of what I did: 

Thanks

What question type are you using and have you paste this in the same question JS?


You are probably using simple layout, try using something like this instead :

let box = document.querySelector(".text-input");
box.onpaste = function () {
return false;
}

 


You are probably using simple layout, try using something like this instead :

let box = document.querySelector(".text-input");
box.onpaste = function () {
return false;
}

 

Thank you very much! It works perfectly! 


Leave a Reply