RE: Get array as string --Help

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

 



Yea but implde will loose the "Keys"

Chetan Dattaram Rane
Software Engineer
 
 
-----Original Message-----
From: Thiago Pojda [mailto:thiago.pojda@xxxxxxxxxxxxxxxxxx] 
Sent: Friday, May 09, 2008 5:30 PM
To: 'Zoltán Németh'; 'Chetan Rane'
Cc: 'Shelley'; 'PHP General list'
Subject: RES:  Get array as string --Help

Depending on your needs you could also use implode() and then save it to a
file.


Thiago Henrique Pojda
Desenvolvimento Web
+55 41 3033-7676
thiago.pojda@xxxxxxxxxxxxxxxxxx
Excelência em Softwares Financeiros


-----Mensagem original-----
De: Zoltán Németh [mailto:znemeth@xxxxxxxxxxxxxx] 
Enviada em: sexta-feira, 9 de maio de 2008 08:37
Para: Chetan Rane
Cc: 'Shelley'; 'PHP General list'
Assunto: RE:  Get array as string --Help

> Yet another option is use serialize(array())

or you could use var_export if you need php code
http://php.net/var_export

greets,
Zoltán Németh

>
> Chetan Dattaram Rane
> Software Engineer
>
>
>
> -----Original Message-----
> From: Shelley [mailto:myphplist@xxxxxxxxx]
> Sent: Friday, May 09, 2008 3:11 PM
> To: PHP General list
> Subject:  Get array as string --Help
>
> Hi all,
>
> If I have an array like this:
> $arr = array (
>                 'c' => 'd',
>                 'e' => 'f');
>
> How can I convert this array into a string? I want to write an array into
> a
> file.
>
> Thanks in advance.
>
> --
> Regards,
> Shelley
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
>



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





-- 
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