You need to sign in to do that
Don't have an account?

How to add new line in string?
Hello Folks,
I am using a string to concatenate address fields. Say Address1__c, Address__C, Address__c. When I concatenate these fields it becomes a longer string.
Hence I want to add a new line character into the string, so that when it displays on the page - address 1, address 2 and address 3 would appear on the new line.
How can we achive this? I was trying with adding a '\n' character into the string. But it wasn't working.
Thanks,
Devendra S
Hi,
In Internet explorer, it is '\r\n'
Hi,
Add <br> at the end of each string
Address1__c,\r\n Address__C,\r\nAddress__c
Example:
At the top, add this attribute:
<aura:attribute name="title" type="String" default="Connect, talk shop and swap success stories,<br/> pics and trade secrets with members of the community."/>
In your code, add this to your attribute reference like so:
<aura:unescapedHtml value="{!v.title}" />