Display Addresses in a Single Line in Table Components
This is a great solution that you can use to display addresses in a table component across a single line as opposed to multiple lines by replacing the line break with a comma and a space.
Step 1
In your data table, double click your address field to add the CSS class of "address."
Step 2
Hover over the info icon of your data table to get the value of your component ID.
Step 3
Add the following code to the JavaScript tab of your page.
Remember to change the component ID of the code to the value of your ID found in step 2.
TB.render('component_3', function(data) {
var addresses = $(".address a"),
x;
for (x of addresses) {
y = x.innerHTML;
x.innerHTML = y.replace(/<br>/g, ", ");
}
});