RE: [PHP] Passing array variables in a GET

From: Date: Wed, 22 Oct 2003 18:41:47 +0000
Subject: RE: [PHP] Passing array variables in a GET
Groups: php.general 
Request: Send a blank email to php-general+get-167149@lists.php.net to get a copy of this message
I looked at the page you suggested but it vauge at best. Basically from what I've gathered using serialize with an array screws up the pointers in the array. Is this true? What I've done is this but it doesn't seem to be working... Pull data (two fields) from a mysql table and put the results into two arrays, one for each field Query results for field 1 -> Array1[] Query results for field 2 -> Array2[] Then I create a variable with the imploded data from the arrays $var1=implode(":", $Array1); $var2=implode(":", $Array2); Then serialize the variables... $varSER1=serialize($var1); $varSER2=serialize($var2); Then pass the variables in the url via a GET. It doesn't work however.... Jeff > -----Original Message----- > From: Wouter van Vliet [mailto:wouter@springt.nl] > Sent: Wednesday, October 22, 2003 1:06 PM > To: Jeff McKeon; php-general@lists.php.net > Subject: RE: [PHP] Passing array variables in a GET > > > Take a look at > http://nl.php.net/manual/en/function.serialize.php and > http://nl.php.net/manual/en/function.unseriali> ze.php. Or > if > the keys don't matter and the array has just > one level (strange, I know there's a different term for that, > totally cannot find it in my memory :S) you can consider > join() and split(). > > Wouter > > -----Original Message----- > From: Jeff McKeon [mailto:jmckeon@telaurus.com] > Sent: Wednesday 22 October 2003 18:59 > To: php-general@lists.php.net > Subject: [PHP] Passing array variables in a GET > > Is this possible??? > > $blah[]=(a, b, c); > > <a href="http://www.blah.com/page.php?blah=<?PHP > ECHO $blah > ?>">link</a> > > So basically I have a page that need an array to perform some > function. Can I pass that array variable (and thus it's data) > to it from another page? > > Thanks, > > Jeff > > -- > PHP General Mailing List (http://www.php.net/) To > unsubscribe, visit: http://www.php.net/unsub.php > > > >

« previous php.general (#167149) next »