Track link in a survey to an external page and encode with 1/0 | XM Community
Question

Track link in a survey to an external page and encode with 1/0

  • 12 April 2021
  • 3 replies
  • 11 views

Dear community,
I want to include a link to an external page in my survey (this should open in a new tab). I want to track the respondents who clicked on the link. All participants who clicked on the link should be coded with a 1. All participants who did not click on the link should be coded with a 0. In the survey flow, I have included an embedded data at the appropriate question:
Qualtrics 1.pngIn addition, I have already tried the following code in JavaScript, but unfortunately it does not work.
Qualtrics 2.pngDoes anyone have any further suggestions for me on how I can solve the problem?

Many thanks in advance!


3 replies

Userlevel 7
Badge +21

In your question HTML (see the support pages to find out how to access it) there will be an anchor tag some like this


Change it to:

Thanks ahmedA. But I'm sorry, I do not understand your answer properly. Can you please explain exactly where I can look in the survey for your suggestion? 

Userlevel 7
Badge +21

This is most likely being caused by the question HTML not being setup properly. Check to see if you've assigned the id extLink to your external link.

Leave a Reply