Hi,
I have a column (Products) coming from a read list activity containing all the products purchased by a customer, separated by comma. I want to add each product in a bullet point, so I'm trying to split this targetData field and then create a for each. This is the code I'm using in the html:
<ul>
<% var p = targetData.Products.split(","); %>
<% for each (var products in p){ %>
<li><%= products %></li>
<% } %>
</ul>
Unfortunately I get the following error:
Can someone provide me any insights?
Thank you in advance,
Diego
Solved! Go to Solution.
Topics help categorize Community content and increase your ability to discover relevant content.
Views
Replies
Total Likes
Hello @Gabsulibio
Try this:
<ul>
<% var p1 = targetData.Products;
var p=p1.split(",");
%>
<% for each (var products in p){ %>
<li><%= products %></li>
<% } %>
</ul>
Hello @Gabsulibio
Try this:
<ul>
<% var p1 = targetData.Products;
var p=p1.split(",");
%>
<% for each (var products in p){ %>
<li><%= products %></li>
<% } %>
</ul>
Thank you @_Manoj_Kumar_
It's working!
Views
Replies
Total Likes