Is there a question type for URLs (or links)? | XM Community
Skip to main content
Solved

Is there a question type for URLs (or links)?

  • October 7, 2021
  • 3 replies
  • 372 views

Forum|alt.badge.img+3
  • Level 2 ●●
  • 22 replies

One of the questions in my survey asks the respondent to enter a URL (a link).

  • Is there a question type for this?

  • Or if entered in a text field, is there an option to validate a URL?

Thanks

Best answer by ElieD

There is no built-in option to validate url format.

But you can add custom validation to a text field :
image.pngThen you have to choose Regex :
image.png
I've found a regex you just have to paste in your validation :
((([A-Za-z]{3,9}:(?:\\/\\/)?)(?:[-;:&=\\+\\$,\\w]+@)?[A-Za-z0-9.-]+|(?:www.|[-;:&=\\+\\$,\\w]+@)[A-Za-z0-9.-]+)((?:\\/[\\+~%\\/.\\w-_]*)?\\??(?:[-\\+=&;%@.\\w_]*)#?(?:[\\w]*))?)
Reference : https://stackoverflow.com/a/8234912

3 replies

ElieD
QPN Level 4 ●●●●
Forum|alt.badge.img+39
  • QPN Level 4 ●●●●
  • 132 replies
  • Answer
  • October 7, 2021

There is no built-in option to validate url format.

But you can add custom validation to a text field :
image.pngThen you have to choose Regex :
image.png
I've found a regex you just have to paste in your validation :
((([A-Za-z]{3,9}:(?:\\/\\/)?)(?:[-;:&=\\+\\$,\\w]+@)?[A-Za-z0-9.-]+|(?:www.|[-;:&=\\+\\$,\\w]+@)[A-Za-z0-9.-]+)((?:\\/[\\+~%\\/.\\w-_]*)?\\??(?:[-\\+=&;%@.\\w_]*)#?(?:[\\w]*))?)
Reference : https://stackoverflow.com/a/8234912


Forum|alt.badge.img
  • 1 reply
  • May 31, 2023

I’m having the same issue. Has Qualtrics updated this validation type?


JoseS
Administrator
Forum|alt.badge.img+20
  • Administrator
  • 449 replies
  • June 2, 2023

I’m having the same issue. Has Qualtrics updated this validation type?

Hello @View_QUT, unfortunately there is still no built-in option to validate a url in a Text Entry question. However, the Regex solution on this thread is still able to be used and is functioning as expected. 🙂

Are you having issues implementing this solution?