An alternative to the text
parameter is the data
parameter. The data
parameter can be useful for three scenarios:
- Sending unicode data
- Sending binary data
- To avoid new lines being inserted into message text
If you cannot disable automatic line wrapping in your email client application, the text
parameter can be specified on multiple lines. This does however cause new line characters to become part of the SMS message text. These new lines are a problem for unicode messages, binary messages or long text messages that you want to keep to one message part.
Unlike the text
parameter, using the data
parameter on multiple lines will not result in a new line being added to the SMS message. It will also remove any white space before and after the message data
lines, ensuring an unbroken text line in the SMS.
In the below example, the email client inserts a new line before the word 'here':
Note: Another alternative to the text
parameter is the urltext
parameter. This allows you to use a URL encoded string, which is useful when sending special characters such as "new line" or Greek text.