Re: Converting print_r() output to an array

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

 



Hi,

May be you want to take a look at serialize and unserialize functions,
serialize generates a string from a variable and then unserialize can
give you the value of the variable back from the string.

Regards,

Jonathan


On Thu, Oct 1, 2009 at 12:07 AM, James Colannino <james@xxxxxxxxxxxxx> wrote:
> Hey everyone, I was pretty sure there was an easy built-in solution for
> what I want to do, but I've been googling around with no luck.
> Basically, I just want to take a string containing the output of
> print_r() and convert it back into an array again.
>
> That is possible, right?  If so, how do I go about it?  If not, what's a
> quick and easy way to parse a string and turn it into an array (I don't
> necessarily need the string to be in the format print_r returns).
>
> Thanks!
>
> James
>
> --
> 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