View Full Version : sending formated sms with PHP

12-09-2010, 01:48 PM
Hi all,
I have done a small program to send sms. for ex. the text is having 3 line and i want to put a <br> in each line. I tried every possible way. char(10).char(13) , <br> , <pre>. but nothing works
the sms sending is working smoothly. but all text goes as continues lines
How can i achieve this??

Million thanks

12-10-2010, 05:51 AM
Most SMS is a plain text message so you'll need to convert any <br> to a \n\r character. If you are entering this in a text area just hitting enter will work... or same via PHP

$messageToSend = 'This is a new
message to send
text message';

12-13-2010, 02:13 PM
There is a loop which is forming the text so i cannot give enters in the lines. Also i have already tried \n\r. nothing works.

12-29-2010, 02:31 AM
Can we see your coding?