Badie
10-02-2007, 03:57 PM
Hi,
I have 2 pages , one contain contact form and the other is to make validation, user Must enter his email, name & message.
When someone fill the message (textarea) and forget to put the other information and click send , the data will be posted in the 2ed page, its check the fields so, if something messing the 2ed page takes him back to the contact form page and shows a error message.
in order to make the customer add the missing information without rewrite the message that he is already sent, i send back the message information by session and its display back in the textarea.
The Problem:
if the write his message with break using ENTER, and he send the data , when its return its will show up with \n ..
for example if he write in the text area
Hi
i want some help
then he click send , when he back to the page , the data in the text area will be :
hi\n\iwantsomehelp
i try many times with nl2br and replace functions but nothing work !!
any idea ?
Thanks
I have 2 pages , one contain contact form and the other is to make validation, user Must enter his email, name & message.
When someone fill the message (textarea) and forget to put the other information and click send , the data will be posted in the 2ed page, its check the fields so, if something messing the 2ed page takes him back to the contact form page and shows a error message.
in order to make the customer add the missing information without rewrite the message that he is already sent, i send back the message information by session and its display back in the textarea.
The Problem:
if the write his message with break using ENTER, and he send the data , when its return its will show up with \n ..
for example if he write in the text area
Hi
i want some help
then he click send , when he back to the page , the data in the text area will be :
hi\n\iwantsomehelp
i try many times with nl2br and replace functions but nothing work !!
any idea ?
Thanks
