Re: saving and retrieving an array from a database

From: Date: Mon, 07 Aug 2006 12:52:45 +0000
Subject: Re: saving and retrieving an array from a database
Groups: php.general 
Request: Send a blank email to php-general+get-240237@lists.php.net to get a copy of this message
ok this seem to work but how do I bring it back? This is what I have so far. <? $first[] = array('appple', 'pear', 'banana'); $second = serialize($first); $third[]= unserialize($second); echo $second; //outputs serialized data echo $third[1]; ?> ----- Original Message ----- From: "Peter Lauri" <lists@dwsasia.com> To: "'Ross'" <ross@aztechost.com>; <php-general@lists.php.net> Sent: Monday, August 07, 2006 8:23 AM Subject: RE: [PHP] saving and retrieving an array from a database
http://se2.php.net/serialize /Peter -----Original Message----- From: Ross [mailto:ross@aztechost.com] Sent: Monday, August 07, 2006 7:19 PM To: php-general@lists.php.net Subject: [PHP] saving and retrieving an array from a database Hi, I have an array of values. I want to save them with php to a single field in my database and then retrieve them to an array. What is the simplest way to achive this? Ross -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php


« previous php.general (#240237) next »