Skip to main content
added 72 characters in body
Source Link

Use BuildRowsetFromString to split your delimited string into Ids.

Try this :

%%[
    var @ProductID, @Product, @ProductRecord, @Ids
    Set @ProductID = AttributeValue('Account:PersonContact:Last_abandoned_cart_lineitem_Product_IDs__c')
    set @Ids = BuildRowsetFromString(@ProductID, ",")
    FOR @i = 1 to ROWCOUNT(@Ids) DO
        SET @ProductId = Field(ROW(@ids, @i),1)
        SET @Product = LookupRows("EcommerceProductImageUrls", "ProductID", @ProductID)
        SET @ProductRecord = row(@Product, 1)
]%%
    <center><img style="border: 0;display: block;height: auto;width: 150px;max-width: 1200px;" alt="" width="150" src="%%=Field(@ProductRecord, "ProductImageURL")=%%"></center>
    <p style="text-align: center; font-size: 16px"><span style="color: #FFFFFF">%%=Field(@ProductRecord, "ProductTitle")=%%</span></p>
%%[ next @i ]%%

See here and here for further details on how to split delimited strings.

Of course add the correct checks on max values and non empty strings.

Try this :

%%[
    var @ProductID, @Product, @ProductRecord, @Ids
    Set @ProductID = AttributeValue('Account:PersonContact:Last_abandoned_cart_lineitem_Product_IDs__c')
    set @Ids = BuildRowsetFromString(@ProductID, ",")
    FOR @i = 1 to ROWCOUNT(@Ids) DO
        SET @ProductId = Field(ROW(@ids, @i),1)
        SET @Product = LookupRows("EcommerceProductImageUrls", "ProductID", @ProductID)
        SET @ProductRecord = row(@Product, 1)
]%%
    <center><img style="border: 0;display: block;height: auto;width: 150px;max-width: 1200px;" alt="" width="150" src="%%=Field(@ProductRecord, "ProductImageURL")=%%"></center>
    <p style="text-align: center; font-size: 16px"><span style="color: #FFFFFF">%%=Field(@ProductRecord, "ProductTitle")=%%</span></p>
%%[ next @i ]%%

See here and here for further details on how to split delimited strings.

Of course add the correct checks on max values and non empty strings.

Use BuildRowsetFromString to split your delimited string into Ids.

Try this :

%%[
    var @ProductID, @Product, @ProductRecord, @Ids
    Set @ProductID = AttributeValue('Account:PersonContact:Last_abandoned_cart_lineitem_Product_IDs__c')
    set @Ids = BuildRowsetFromString(@ProductID, ",")
    FOR @i = 1 to ROWCOUNT(@Ids) DO
        SET @ProductId = Field(ROW(@ids, @i),1)
        SET @Product = LookupRows("EcommerceProductImageUrls", "ProductID", @ProductID)
        SET @ProductRecord = row(@Product, 1)
]%%
    <center><img style="border: 0;display: block;height: auto;width: 150px;max-width: 1200px;" alt="" width="150" src="%%=Field(@ProductRecord, "ProductImageURL")=%%"></center>
    <p style="text-align: center; font-size: 16px"><span style="color: #FFFFFF">%%=Field(@ProductRecord, "ProductTitle")=%%</span></p>
%%[ next @i ]%%

See here and here for further details on how to split delimited strings.

Of course add the correct checks on max values and non empty strings.

deleted 1 character in body
Source Link

Try this :

%%[
    var @ProductID, @Product, @ProductRecord, @Ids
    Set @ProductID = AttributeValue('Account:PersonContact:Last_abandoned_cart_lineitem_Product_IDs__c')
    set @Ids = BuildRowsetFromString(@ProductID, ",")
    FOR @i = 1 to ROWCOUNT(@Ids) DO
        SET @ProductId = Field(ROW(@ids, @i),1)
        SET @Product = LookupRows("EcommerceProductImageUrls", "ProductID", @ProductID)
        SET @ProductRecord = row(@Product, 1)
]%%
    <center><img style="border: 0;display: block;height: auto;width: 150px;max-width: 1200px;" alt="" width="150" src="%%=Field(@ProductRecord, "ProductImageURL")=%%"></center>
    <p style="text-align: center; font-size: 16px"><span style="color: #FFFFFF">%%=Field(@ProductRecord, "ProductTitle")=%%</span></p>
%%[ next @i ]%%

See here and here for further details on how to split a separated stringdelimited strings.

Of course add the correct checks on max values and non empty strings.

Try this :

%%[
    var @ProductID, @Product, @ProductRecord, @Ids
    Set @ProductID = AttributeValue('Account:PersonContact:Last_abandoned_cart_lineitem_Product_IDs__c')
    set @Ids = BuildRowsetFromString(@ProductID, ",")
    FOR @i = 1 to ROWCOUNT(@Ids) DO
        SET @ProductId = Field(ROW(@ids, @i),1)
        SET @Product = LookupRows("EcommerceProductImageUrls", "ProductID", @ProductID)
        SET @ProductRecord = row(@Product, 1)
]%%
    <center><img style="border: 0;display: block;height: auto;width: 150px;max-width: 1200px;" alt="" width="150" src="%%=Field(@ProductRecord, "ProductImageURL")=%%"></center>
    <p style="text-align: center; font-size: 16px"><span style="color: #FFFFFF">%%=Field(@ProductRecord, "ProductTitle")=%%</span></p>
%%[ next @i ]%%

See here and here for further details on how to split a separated string.

Of course add the correct checks on max values and non empty strings.

Try this :

%%[
    var @ProductID, @Product, @ProductRecord, @Ids
    Set @ProductID = AttributeValue('Account:PersonContact:Last_abandoned_cart_lineitem_Product_IDs__c')
    set @Ids = BuildRowsetFromString(@ProductID, ",")
    FOR @i = 1 to ROWCOUNT(@Ids) DO
        SET @ProductId = Field(ROW(@ids, @i),1)
        SET @Product = LookupRows("EcommerceProductImageUrls", "ProductID", @ProductID)
        SET @ProductRecord = row(@Product, 1)
]%%
    <center><img style="border: 0;display: block;height: auto;width: 150px;max-width: 1200px;" alt="" width="150" src="%%=Field(@ProductRecord, "ProductImageURL")=%%"></center>
    <p style="text-align: center; font-size: 16px"><span style="color: #FFFFFF">%%=Field(@ProductRecord, "ProductTitle")=%%</span></p>
%%[ next @i ]%%

See here and here for further details on how to split delimited strings.

Of course add the correct checks on max values and non empty strings.

added 79 characters in body
Source Link

Try this :

%%[
    var @ProductID, @Product, @ProductRecord, @Ids
    Set @ProductID = AttributeValue('Account:PersonContact:Last_abandoned_cart_lineitem_Product_IDs__c')
    set @Ids = BuildRowsetFromString(@ProductID, ",")
    FOR @i = 1 to ROWCOUNT(@Ids) DO
        SET @ProductId = Field(ROW(@ids, @i),1)
        SET @Product = LookupRows("EcommerceProductImageUrls", "ProductID", @ProductID)
        SET @ProductRecord = row(@Product, 1)
]%%
    <center><img style="border: 0;display: block;height: auto;width: 150px;max-width: 1200px;" alt="" width="150" src="%%=Field(@Product@ProductRecord, "ProductImageURL")=%%"></center>
    <p style="text-align: center; font-size: 16px">
      <span16px"><span style="color: #FFFFFF">%%=Field(@Product@ProductRecord, "ProductTitle")=%%</span>
    <span></p>
%%[ next @i ]%%

See here and here for further details on how to split a separated string.

Of course add the correct checks on max values and non empty strings.

Try this :

%%[
    var @ProductID, @Product, @Ids
    Set @ProductID = AttributeValue('Account:PersonContact:Last_abandoned_cart_lineitem_Product_IDs__c')
    set @Ids = BuildRowsetFromString(@ProductID, ",")
    FOR @i = 1 to ROWCOUNT(@Ids) DO
        SET @ProductId = Field(ROW(@ids, @i),1)
        SET @Product = LookupRows("EcommerceProductImageUrls", "ProductID", @ProductID)
]%%
    <center><img style="border: 0;display: block;height: auto;width: 150px;max-width: 1200px;" alt="" width="150" src="%%=Field(@Product, "ProductImageURL")=%%"></center>
    <p style="text-align: center; font-size: 16px">
      <span style="color: #FFFFFF">%%=Field(@Product, "ProductTitle")=%%</span>
    </p>
%%[ next @i ]%%

See here and here for further details on how to split a separated string.

Of course add the correct checks on max values and non empty strings.

Try this :

%%[
    var @ProductID, @Product, @ProductRecord, @Ids
    Set @ProductID = AttributeValue('Account:PersonContact:Last_abandoned_cart_lineitem_Product_IDs__c')
    set @Ids = BuildRowsetFromString(@ProductID, ",")
    FOR @i = 1 to ROWCOUNT(@Ids) DO
        SET @ProductId = Field(ROW(@ids, @i),1)
        SET @Product = LookupRows("EcommerceProductImageUrls", "ProductID", @ProductID)
        SET @ProductRecord = row(@Product, 1)
]%%
    <center><img style="border: 0;display: block;height: auto;width: 150px;max-width: 1200px;" alt="" width="150" src="%%=Field(@ProductRecord, "ProductImageURL")=%%"></center>
    <p style="text-align: center; font-size: 16px"><span style="color: #FFFFFF">%%=Field(@ProductRecord, "ProductTitle")=%%</span></p>
%%[ next @i ]%%

See here and here for further details on how to split a separated string.

Of course add the correct checks on max values and non empty strings.

added 73 characters in body
Source Link
Loading
deleted 24 characters in body
Source Link
Loading
added 237 characters in body
Source Link
Loading
Source Link
Loading