Solved

Dynamic button for to buy viewed item

  • 13 July 2021
  • 3 replies
  • 801 views

Badge +3

I’m sure it’s in here somewhere, but I’ve looked and looked and can’t find what I’m looking for. I have an email that contains links to recently viewed items. I want to add a button that sends them to the specific product.

So basically, I want to duplicate the “Buy Now” button that’s native to the product block, but send them to their most viewed item. 

 

icon

Best answer by Dov 13 July 2021, 22:19

View original

3 replies

Userlevel 7
Badge +61

Hi @porter,

Thank you for sharing your question with the Klaviyo Community.

You can use the following snippet in the button block:

{{ person.ViewedItems.0.Url }}

I assume you have already gone through our doc on inserting recently viewed items into an email, if not I would check that out as well. I also recommend reviewing our doc on using event variables to personalize flows and past posts on this topic, linking those below as well

Thanks for being a member of our Community!

Badge +3

This is fantastic! Is there a blog or article that contains all these different snippets?

Userlevel 7
Badge +61

Hi @porter,

The tag is included in inserting recently viewed items into an email. In addition to those resources, I also recommend checking out template tags and variable syntax for more great information on populating templates with dynamic variables. 

Reply