Skip to main content
Solved

Issue with product link displayed in 'back in stock' flow

  • February 16, 2022
  • 2 replies
  • 74 views

Forum|alt.badge.img+3

Hi Guys, 

I’m seeing “&” in a 'back in stock' flow product link that the customer receives. 

In context, this is how the link appears to the customer:   Vendetta Premium Navy Pick & Pick Suit

Googling it, it sounds like the “&” symbol is not decoding properly?

Perhaps worth mentioning is that our website uses a custom backend, not shopify. 

I’m not our IT guy (as you can probably tell!), but I’m seeing if this is something I can fix on my own, or at least go to them with a rough idea on what’s wrong. 

Any thoughts would be greatly appreciated :-) 

Best answer by stephen.trumble

Hey @Wmorris2468 

Thank you so much for coming to the Klaviyo Community for help with this!

As product names are event variables that pull in dynamic data for each email, it was a great idea to add a filter to this variable! You are on the right track!  Filters allow you to modify the format and content of variables in a message. We want to change how the variables are displayed because they have additional symbols and letters we don’t want to see. To apply a filter to a template tag, the following elements should be added:

  • A pipe symbol ( | ) after the variable name
  • The filter name 
  • If the filter takes any arguments (i.e., additional parameters or inputs), add a colon, followed by the argument(s) 

 

I would recommend adding the |safe filter to the product name variables you want to change. In total, the new filter should be applied like this {{ event.Name|safe }} 

View original
Did this topic or the replies in the thread help you find an answer to your question?

2 replies

stephen.trumble
Community Manager
Forum|alt.badge.img+60
  • Community Manager
  • 1518 replies
  • Answer
  • February 17, 2022

Hey @Wmorris2468 

Thank you so much for coming to the Klaviyo Community for help with this!

As product names are event variables that pull in dynamic data for each email, it was a great idea to add a filter to this variable! You are on the right track!  Filters allow you to modify the format and content of variables in a message. We want to change how the variables are displayed because they have additional symbols and letters we don’t want to see. To apply a filter to a template tag, the following elements should be added:

  • A pipe symbol ( | ) after the variable name
  • The filter name 
  • If the filter takes any arguments (i.e., additional parameters or inputs), add a colon, followed by the argument(s) 

 

I would recommend adding the |safe filter to the product name variables you want to change. In total, the new filter should be applied like this {{ event.Name|safe }} 


Forum|alt.badge.img+3
  • Author
  • Contributor IV
  • 7 replies
  • February 18, 2022

Thank you very much @stephen.trumble

I'll have a crack at this myself, and I'll let our IT guys know if it comes to it.

Thanks again!