Jump to content

How to convert an recursive array into a string and vice versa


Recommended Posts

Maybe this belongs to the "PHP Newbie forum, but whatver..."

Let's say I have an array which contains array which contain arrays etc...
How can I convert it to a string so I can put it in a MySQL entry in order to take it back later?

Maybe there's a smarter way to do what I'm trying to do. Any ideas? Thank you.
[!--quoteo(post=370727:date=May 3 2006, 12:58 AM:name=Horst Azeglio)--][div class=\'quotetop\']QUOTE(Horst Azeglio @ May 3 2006, 12:58 AM) [snapback]370727[/snapback][/div][div class=\'quotemain\'][!--quotec--]
I'm sure it can be done without nested arrays, but I'm sure I will need to convert matryoshka-like arrays to strings someday.
[/quote]
look serialize()

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.