Re: [PHP] Storing data structires in DB

2005-03-29 Thread GamblerZG
> You are looking for serialize here. I bet you'd be better off with an > existing XML format for something like this though. WDDX is an unusual extension for most of the hosting providers. And writing my own XML serialization mechanism is an overkill. Moreover, XML is not-compact, harder to edit

Re: [PHP] Storing data structires in DB

2005-03-26 Thread Rasmus Lerdorf
GamblerZG wrote: Why would you _manually_ edit a serialized array??? One would think you would UNSERIALIZE (http://us4.php.net/unserialize) the serialized array *before* working with the data. Well, I guess my initial posting was a bit misleading. I'm writing a content management system, and t

Re: [PHP] Storing data structires in DB

2005-03-26 Thread GamblerZG
Why would you _manually_ edit a serialized array??? One would think you would UNSERIALIZE (http://us4.php.net/unserialize) the serialized array *before* working with the data. Well, I guess my initial posting was a bit misleading. I'm writing a content management system, and that system needs t

Re: [PHP] Storing data structires in DB

2005-03-24 Thread John Nichel
GamblerZG wrote: Output of serialize() is barely readable and definetely is not suited for manual editing. It is quite simple to create var_export() clone that does not add junk to it's output. But then I would need to exec() the string to get a data structure back, which is bad security practi

RE: [PHP] Storing data structires in DB

2005-03-24 Thread Chris W. Parker
GamblerZG on Thursday, March 24, 2005 1:15 PM said: > Output of serialize() is barely readable and definetely is not suited > for manual editing. [snip /] > Is there any good way to store/retrieve data structures > (multidimetional arrays) to/from database? Maybe I

[PHP] Storing data structires in DB

2005-03-24 Thread GamblerZG
Output of serialize() is barely readable and definetely is not suited for manual editing. It is quite simple to create var_export() clone that does not add junk to it's output. But then I would need to exec() the string to get a data structure back, which is bad security practice. Is there any