cancel
Showing results for 
Search instead for 
Did you mean: 

Hyperlink URL Error in HTML/XML Generator

lillyknox
New Contributor

I am working on a pipeline and have data being formatted as two separate HTML tables in an XML Generator Snap that is being mapped to an HTML Text Email Sender. I am attempting to format the hyperlink in one of the cells of the table to show the link as different text as opposed to the full URL. I am able to achieve the desired formatting but when the hyperlink is clicked, I am taken to a completely different link than the one I passed and get a "This site can't be reached" error.

I am passing the link as a parameter for the pipeline (when I copy and paste this link, I reach the website with no problem) :

 Screenshot 2024-08-07 145428.png

Formatting the link in the XML Generator:

Screenshot 2024-08-07 145334.png

The link appears how I would like in the formatted email:

Screenshot 2024-08-07 145459.png

But this is the link I am taken to when I click the hyperlink or copy the URL and paste into any browser:

Screenshot 2024-08-07 145305.png

 

Any thoughts??

5 REPLIES 5

aditya_gupta41
Contributor

In Pipeline Properties, try putting your URL in double quotes.

aditya_gupta41_0-1723193946111.png

Hello, I tried this and changed the XML to show the following and I got the desired "Test" but it was not linked. is there something else I need to do with the quotes in the XML since the quotes are there in the pipeline parameter?

<a href = $item.Link_To_SF_CT_Record>Test</a>

 

Somehow, I am unable to upload my slp pipeline which have the solution, but here I am attaching the SS for your reference.

aditya_gupta41_1-1723438953718.png

aditya_gupta41_0-1723438906062.png

aditya_gupta41_2-1723439011478.pngaditya_gupta41_3-1723439044947.png

 

<html>
    <body>
            <a href="$item.Link_To_SF_CT_Record">Test</a>
    </body>
</html>

 

aditya_gupta41_5-1723439313095.png

 

 

 

Aleksandar_A
Contributor III

Hello @lillyknox,

In order to access a Pipeline Parameter in the XML Generator Snap, you have to use the 

${_pipelineParamName}. Could you try with the following expression for the link?

 

<a href="${_Link_To_SF_CT_Record}">TEST</a>

 

Try this and let me know if this works for you.

Regards,

Aleksandar.