how do I know when users press the ENTER key on textarea so I will be able to replace it with <br>?
do I do the following code? preg_replace("\n\r","<br>",$content);
try nl2br
HTH
Toby
thank you pal, you helped me a lot. i read the comments ,which were written there, and saw that :
$text= str_replace('\r\n', '\n', $text);
well, it works as well as nl2br function but thank a lot for your support.