Posted by Berimor on 01/14/07 21:13
On Sun, 14 Jan 2007 00:42:37 +0200, ghostwalker <mark@weblogica.co.uk> =
wrote:
> Hi
>
> I have an HTML form with a textarea on it. When submitted (using 'get'=
> not 'post') this forms action php file simply does this to retrieve th=
e
> values:
>
> $message =3D $_GET["message"];
>
> Now it all works fine but I get the string in one long string with no
> '\n' where the user pressed 'return key'
>
> How can I get the carriage returns in the textarea to be replaced with=
> a '\n' ??? Its driving me nuts here!!
>
You mean that returns desappear if you're going to display information a=
s =
text in HTML document?
Sure you have to use nl2br function to replace all '\n' with '<br>'.
-- =
Exact Meta Search | Major Search Engine http://exactsearcher.com
Web Design Essex | Multimedia | Printing http://nextwave.co.uk
Navigation:
[Reply to this message]
|