# Displaying data with multiple rows, in a template

**URL:** <https://community.hubspot.com/t/displaying-data-with-multiple-rows-in-a-template/91107>\
**Category:** APIs & Integrations\
**Tags:** companies, email-deliverability\
**Created:** [October 4, 2023, 5:06pm UTC](https://community.hubspot.com/t/displaying-data-with-multiple-rows-in-a-template/91107 "2023-10-04T17:06:59Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![CraigWish](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/craigwish/32/39641_2.png) [@CraigWish](https://community.hubspot.com/u/CraigWish)\
**Post date:** [October 4, 2023, 5:06pm UTC](https://community.hubspot.com/t/displaying-data-with-multiple-rows-in-a-template/91107/1 "2023-10-04T17:06:59Z")

</div>

Hi everyone, I hope someone could help.  
I have my API bringing a number of values on one property. For example:

```lia-code-sample
Topic one 
Topic two
Topic three
Topic four

```

When I added them to an email template the display email looks like this:

`Topic one Topic two Topic three Topic four`

How do you modify the email template to represent the line breaks?

---

<div class="post-metadata">

**Author:** ![Jaycee\_Lewis](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/jaycee_lewis/32/61352_2.png) [@Jaycee\_Lewis](https://community.hubspot.com/u/Jaycee_Lewis)\
**Post date:** [October 5, 2023, 8:29pm UTC](https://community.hubspot.com/t/displaying-data-with-multiple-rows-in-a-template/91107/2 "2023-10-05T20:29:54Z")

</div>

Hey, @CraigWish 👋

Have you looked into using the HubL filter `[split](https://developers.hubspot.com/docs/cms/hubl/filters#split)`? And using a for loop? The one issue I see is you are not using a separator for your values. For that, I do not have a filter option. Here’s a quick simple example assuming commas were used:

```lia-code-sample
{% set topics = "Topic one,Topic two,Topic three,Topic four"|split(',') %}
{% for topic in topics %}
 {{ topic }}<br/>
{% endfor %}

```

Hey, @Anton @Stephanie-OG, is there a better or different way you’d handle this type of challenge?

Best,

Jaycee

---

<div class="post-metadata">

**Author:** ![CraigWish](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/craigwish/32/39641_2.png) [@CraigWish](https://community.hubspot.com/u/CraigWish)\
**Post date:** [January 12, 2024, 3:01pm UTC](https://community.hubspot.com/t/displaying-data-with-multiple-rows-in-a-template/91107/3 "2024-01-12T15:01:31Z")

</div>

Thank you [@Jaycee\_Lewis](https://community.hubspot.com/t5/user/viewprofilepage/user-id/127074) - let me try this.  
What I’m trying, without success yet are:

- Changing the property type to Rich Text
- Using the API to import data using the following format

`Topic one<br>Topic two<br>Topic three<br>Topic four​`

However, when I display the content within the template it display’s the like the above code snipet… it doesn’t know \<br\> is HTML.

---

<div class="post-metadata">

**Author:** ![CraigWish](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/craigwish/32/39641_2.png) [@CraigWish](https://community.hubspot.com/u/CraigWish)\
**Post date:** [January 12, 2024, 3:24pm UTC](https://community.hubspot.com/t/displaying-data-with-multiple-rows-in-a-template/91107/4 "2024-01-12T15:24:31Z")

</div>

I’m trying to figure out the. synctax for using Spilit on a property.  
For example:

```lia-code-sample
{% set topics = {{comapany.property_name}}"|split('<br>') %}
{% for topic in topics %}
 {{ topic }}<br/>
{% endfor %}

```

[@Jaycee\_Lewis](https://community.hubspot.com/t5/user/viewprofilepage/user-id/127074) what do you think?
