Skip to main content

Hey,

 

I’ve been stuck on this for a few hours — I’m looking for ways to show custom content blocks based on products recently purchased.

 

Each content block links to a “How to use PRODUCT” article on the website.

 

Therefore, if customer purchases a product that contains the word “Spray” in the title, they get shown the relevant content block which links to the correct article.

 

Here’s the formats I’ve tried:

‘Spray’ in event.Items
"Spray" in event.best sellers

'Spray' in event|lookup:Items
"SPRAY" in event.ITEMS
event.Items|default:'Spray' 
{{ event.Items|default:Stick }}
lookup.Items|default:'Spray' 
'Spray' in person|lookup:Item

event.Items|0:'Spray'

Hey @Lucasusername 

Welcome to the community and congrats on your first post!

If you have a specific product you want it to look for, you can manually apply a custom property to the profiles. What you can do is, set up a segment that is like this:

What someone has done > ordered product > at least once over all time > where SKU equals > 'SKU'

You don't have to use SKU, you can use other identifier in that section of the segment as well to target the specific product. 

Then, you can set up a segment triggered flow, and in that flow, use an update property action step, to update the property of everyone with a specific custom property. 

?name=image.png

Then, you can use this property to show/hide specific content in your placed order email. You can set up the conditional logic like this - 

person|lookup:'NewProperty' == 'NewPropertyValue'

I know this is a bit detailed and long, but wanted to provide the work around for you that way you didn't have to export then import the profiles but instead can use our flows to set that custom property in the profile data to use. Now, this would only be used if you wanted to show/hide based on past purchases. 

If you just wanted to show/hide a block based on the order that triggered them into the flow, we can do that, by using the event data. This guide has more details on that as well - https://help.klaviyo.com/hc/en-us/articles/115005258208 - this community post also goes through this in more detail - https://community.klaviyo.com/email-templates-and-coupons-32/using-show-hide-blocks-4894

Hope this helps!


Hi @stephen.trumble, thanks for this!

 

I followed your instructions and it seems to be working.

 

Can it only add in 1 custom property at a time? With the current setup, that property gets overridden for each product:

 


Reply