Re: explode string at new line

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



That's exactly correct. Except I /think/ you should use "\n" instead of '\n'.

On 6/5/07, Davi <davividal@xxxxxxxxxxxxxxxx> wrote:

Hi all.

I've the fowlling string:

$_POST["my_text"]="hi...\nthis is my multi-line\ntext";

Can I use explode to have something like:

$str[0]="hi...";
$str[1]="this is my multi-line";
$str[2]="text";

$str=explode($_POST["my_text"],'\n');


TIA and sorry the *very* poor english.


--
Davi Vidal
davividal@xxxxxxxxxxxxxxxx
davividal@xxxxxxxxx
--
"Religion, ideology, resources, land,
spite, love or "just because"...
No matter how pathetic the reason,
it's enough to start a war. "
--------------------------------------------------------
Por favor não faça top-posting, coloque a sua resposta abaixo desta linha.
Please don't do top-posting, put your reply below the following line.
--------------------------------------------------------



--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux