Split data in a field

Siva_K
Level 1

Split data in a field

I have one marketo field which collects the course information the user is interested in. I send a reminder email of all the courses and I use the field token in the email.

But when I use token, the output in body of the email is shown as below:

Course selected: Course1- course name, course timing, course location; course 2 - course name, course timing, course location; course 3 - course name, course timing, course location etc.

This is looking very ugly in the email.

I want the output in email to be:

Course Selected:

Course 1 - course name, course timing, course location

Course 2 - course name, course timing, course location

Course 3 - course name, course timing, course location

etc

Is there any way to split the information. Please let me know.

1 REPLY 1
SanfordWhiteman
Level 10 - Community Moderator

Re: Split data in a field

Yes, easily done with a Velocity ("Email Script") token:

$display.list($lead.coursesSelected.split(";\s?"),"<br>")