Skip to main content
Solved

check value for a variable in a list


Forum|alt.badge.img+2

Hi,

This is regarding a ship confirmation email that I am building using the drag drop

 

the email is going to look like

 

These Items are on their way

Shipped Item 1

Shipped Item 2

 

Other Items in your Order

Delivered Items

Delivered Item 1

Delivered Item 2

 

In Process Items

In process Item 1

In process Item 2

 

Now I am getting the information in this format

<Event>

<Shipment>

    status

   <shipmentItem>

<shipmentItem>

</Shipment>

<Shipment>

    status

   <shipmentItem>

<shipmentItem>

</Shipment>

</Event>

 

My question is how do i check the value of status to decide if i should display

Other Items in your Order

 

Note staus can have values : Shipped, Delivered, In Process

Best answer by Brian Turcotte

Hi @PartsAvatar!

 

I can think of two ways to accomplish this off the bat:

  1. Show/Hide Blocks. This function allows you to show content to some profiles based on their saved properties or events, and different content to other profiles based on their saved properties/events, all within one email:


     

  2. If/Else Statements. Using If/Endif statements can be used to show certain copy if the viewer meets the if/endif statement requirements, based on their saved profile properties:

     

Both of these options allow you to show certain content based on events/properties that are specific to the recipient, so they should allow you to accomplish your use case.

 

Thanks for using the Community!

- Brian

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

2 replies

Brian Turcotte
Forum|alt.badge.img+37
  • Klaviyo Alum
  • 1393 replies
  • Answer
  • March 1, 2023

Hi @PartsAvatar!

 

I can think of two ways to accomplish this off the bat:

  1. Show/Hide Blocks. This function allows you to show content to some profiles based on their saved properties or events, and different content to other profiles based on their saved properties/events, all within one email:


     

  2. If/Else Statements. Using If/Endif statements can be used to show certain copy if the viewer meets the if/endif statement requirements, based on their saved profile properties:

     

Both of these options allow you to show certain content based on events/properties that are specific to the recipient, so they should allow you to accomplish your use case.

 

Thanks for using the Community!

- Brian


Omar
Partner - Platinum
Forum|alt.badge.img+46
  • 2025 Champion
  • 494 replies
  • March 4, 2023

@PartsAvatar, exactly what @Brian Turcotte said!

Or have it shown in order with the status behind it and don't use the if/else show/hide function.

 

Omar Lovert // Polaris Growth // Klaviyo Master Platinum Partner

We help with e-commerce growth through CRO, Klaviyo and CVO