Making Multiple-Choice Variable Choices Hyperlinks

mrreddy534
Tera Contributor

Hi experts, I need your help. I created a multiple-choice variable with three choices, and I want to make those choices hyperlinks. How can I achieve this?

9 REPLIES 9

HIROSHI SATOH
Mega Sage

What action do you want to achieve?
If all you want to do is click on a selection list and navigate to a link, I think you can implement this using client script.

HIROSHISATOH_0-1724483020989.png

HIROSHISATOH_1-1724483080057.png

HIROSHISATOH_2-1724483096780.png

HIROSHISATOH_3-1724483200361.png

 Client Script:

function onChange(control, oldValue, newValue, isLoading) {
    if (isLoading || newValue === '') {
        return;
    }
	
    var url = g_form.getValue('u_choices_hyperlinks');
	if (url) {
		alert("Will be directed"); 
		top.window.open(url,'_blank');
    }
}



 

 

Hi mate, thanks for your assistance. The client wants a multiple-choice variable with three choices, and they want to provide information about those choices by making each choice a hyperlink. The redirecting link would be the same for all. They don't want to use help text for this. My idea was to place a link beside the question, like '(choices info),' but I'm struggling with the logic to implement that.

 

I also tried creating a rich text variable with three checkbox-type variables underneath to mimic the multiple-choice functionality. I added the link to the rich text variable, but there's an issue with the appearance. There's a noticeable gap between the rich text variable and the checkbox variables, making it look like two separate sections rather than a cohesive multiple-choice question. And I want this in catalog item.

 

Could you please give me some ideas on how to approach this?

I'm not sure what you want to achieve.


If you want to display a hyperlink in the service catalog, I think you should set the question's "Question type" to "Text" and create the hyperlink using HTML.

There is multiple choice variable and under that 3 choices are there, Before user selecting the choice, I want to give info about those choices without using help text, this is my requirement.

If we put link in the question itself it is fine or if we make choices as hyperlinks it is also fine.