Yes I believe serialize will work with any array.  When you extract it from
the database simply do $array = unserialize($str) to rebuild the array.
-Kevin

----- Original Message -----
From: "Leon Mergen" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, June 11, 2002 3:59 PM
Subject: Re: [PHP] Array into database


> So this would handle 2-demensional arrays too?
>
> So, if I have
>
> $array = (
>     "foo" => "bar",
>     "wom" => "bat"
>     );
>
>
> it would work?
>
> And darn, that I didn't come up with this (I'm familliar with Java, and
they
> use Serializable) ...
>
> "Stuart Dallas" <[EMAIL PROTECTED]> wrote in message
> [EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
> > On Tuesday, June 11, 2002 at 10:25:36 PM, you wrote:
> > > I would like to know wether it's possible to put an array into a
> database?
> > > If not, what is the best way to archieve something like that?
> >
> > Yes it is. See http://www.php.net/serialize
> >
> > --
> > Stuart
> >
>
>
>
> --
> 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

Reply via email to