use "serialize".

you need to create a table with 2 fields, key & value, where value is a
largetext field.

$str = serialize($array);
mysql_query("insert into table1 (key, value) as ($key, $str)");

then you can select it back out of mysql and use

$result = mysql_query("select....");
$array = unserialize($result[0]->value);

pardon if the php doesn't work, i'm just typing it off the top of my head

"Disko_kex" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
> If I have a normal array like "Array ( [0] => 1 [1] => 3 [2] => 82 )" ,
> and want to store the array in a mysql table and then want to use it.
> How can I do?
>
> // jocke
>


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

Reply via email to