Re: [PHP] Passing Arrays between pages

2005-03-22 Thread Josh Whiting
> >Please can someone tell me how you pass arrays between PHP pages. > > $var = serialize($testArray); > echo ""; > > Then unserialize the variable on the receiving page. To this you might also add an MD5 hash to check for authenticity, depending on what you're doing with that incoming data that

Re: [PHP] Passing Arrays between pages

2005-03-22 Thread PartyPosters
March 22, 2005 10:06 PM Subject: Re: [PHP] Passing Arrays between pages > 1. you can put your array in string using implode() function and on next > page create the array back using explode() function. > $testArray = implode('|', $testArray); > # you will get: "App

Re: [PHP] Passing Arrays between pages

2005-03-22 Thread [EMAIL PROTECTED]
1. you can put your array in string using implode() function and on next page create the array back using explode() function. $testArray = implode('|', $testArray); # you will get: "Apple|Banana|Peach" On next page: $testArray = explode('|', $testArray); 2. use serialize()/unserialize() functio

Re: [PHP] Passing Arrays between pages

2005-03-22 Thread Larry E . Ullman
Please can someone tell me how you pass arrays between PHP pages. $var = serialize($testArray); echo ""; Then unserialize the variable on the receiving page. Larry -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

[PHP] Passing Arrays between pages

2005-03-22 Thread PartyPosters
Hello, Please can someone tell me how you pass arrays between PHP pages. I have tried something like this and have tried many variations of this but nothing working yet ; Page 1 $testArray[0] =Apple; $testArray[1] =Banana; $testArray[2] =Peach; echo ""; Page2 echo $testArray[1]; On different

RE: [PHP] passing arrays?

2003-12-12 Thread motorpsychkill
sychkill'; Php General List > Subject: RE: [PHP] passing arrays? > > > On 12 December 2003 06:07, motorpsychkill wrote: > > > Thanks Tom, that worked! I knew that $$level had something > > to do with it, > > just wasn't sure what exactly. Thanks again. &

RE: [PHP] passing arrays?

2003-12-12 Thread Ford, Mike [LSS]
ent: Thursday, December 11, 2003 9:34 PM > To: motorpsychkill > Subject: Re: [PHP] passing arrays? > > Always use isset() to check if something exists before trying > to use it if > originates externally to the running script. > > you probabley need something like th

RE: [PHP] passing arrays?

2003-12-11 Thread motorpsychkill
Thanks Tom, that worked! I knew that $$level had something to do with it, just wasn't sure what exactly. Thanks again. -m -Original Message- From: Tom Rogers [mailto:[EMAIL PROTECTED] Sent: Thursday, December 11, 2003 9:34 PM To: motorpsychkill Subject: Re: [PHP] passing a

[PHP] passing arrays?

2003-12-11 Thread motorpsychkill
"; print ""; print "" . constant($val) . ""; print ""; } ?> Warning: Variable passed to each() is not an array or object in D:\projects\kf10\test65.php on line 43 Line 43 in the error output refers to the "while" control structure. I can not seem to define $level as

Re: [PHP] passing arrays to a session-variable

2003-02-28 Thread Joshua Moore-Oliva
Try looking at this page http://www.php.net/manual/en/function.serialize.php Josh. On February 28, 2003 08:22 am, Michiel van Heusden wrote: > I'm using this script to test passing arrays to a Session-variable. > > session_start(); > > // method 1 > $_SESSION['array1'] = array("item1", "item2");

[PHP] passing arrays to a session-variable

2003-02-28 Thread Michiel van Heusden
I'm using this script to test passing arrays to a Session-variable. "; echo $array2[0]; ?> method 1 doesn't work until another PHP is loaded, only then the var is ouputted... method 2 works fine, but i'd prefer using $_SESSION all the way instead of session_register any suggestions? grace michie

Re: [PHP] Passing Arrays Through Forms

2003-01-17 Thread Sancar Saran
On Thursday 16 January 2003 20:58, [EMAIL PROTECTED] wrote: > Hello Everyone, > > I've attempted this many times, but have failed to understand it each time. > I want to make it easier for myself to deal with passing variables through > a form. So I thought, why not use a single array variable to d

[PHP] Passing Arrays Through Forms

2003-01-16 Thread @ Nilaab
Hello Everyone, I've attempted this many times, but have failed to understand it each time. I want to make it easier for myself to deal with passing variables through a form. So I thought, why not use a single array variable to do that. If I do such a thing, what steps do I need to take to ensure

Re: [PHP] passing arrays between pages with serialize

2002-08-01 Thread DoL
EMAIL PROTECTED]> Cc: <[EMAIL PROTECTED]> Sent: Wednesday, July 31, 2002 4:57 PM Subject: Re: [PHP] passing arrays between pages with serialize > Hallo DoL, > > it worked when i didn't use urldecode(), just stripslashes(): > > page-1 > $s_array1 = urlencode(serializ

Re: [PHP] passing arrays between pages with serialize

2002-08-01 Thread DoL
Thanks, I found the problem was with the creation of the 2-di array. - Original Message - From: "Martin Towell" <[EMAIL PROTECTED]> To: "'DoL'" <[EMAIL PROTECTED]>; <[EMAIL PROTECTED]> Sent: Wednesday, July 31, 2002 12:21 PM Subject: RE: [

Re: [PHP] passing arrays between pages with serialize

2002-07-31 Thread Valeri Felberg
Hallo DoL, it worked when i didn't use urldecode(), just stripslashes(): page-1 $s_array1 = urlencode(serialize($array1)); header("Location: page-2?h_array1=$s_array1"); page-2 $array1 = unserialize(stripslashes($_GET["h_array1"])); The other way that worked was passing arrays in $_SESSIO

RE: [PHP] passing arrays between pages with serialize

2002-07-30 Thread Martin Towell
Can you post/send the results of doing a print_r() on the first page (the one that's serialising) and the results of the serialize()? -Original Message- From: DoL [mailto:[EMAIL PROTECTED]] Sent: Wednesday, July 31, 2002 2:21 PM To: [EMAIL PROTECTED] Subject: [PHP] passing arrays be

[PHP] passing arrays between pages with serialize

2002-07-30 Thread DoL
Hi I would like to pass three arrays, two of them are two dimensional arrays, to another page (or to the same page just submit to itself) using hidden field and the function serialize. (this is a two dimensional array) page-1 $s_array1 = serialize($array1); page-2 $array1= unserialize(urlde

RE: [PHP] passing arrays

2002-05-24 Thread John Holmes
ED] > Subject: Re: [PHP] passing arrays > > $myarray = unserialize(urldecode($_GET['myarray'])); > or am i wrong? > > Regards Michael > > "Miguel Cruz" <[EMAIL PROTECTED]> schrieb im Newsbeitrag > [EMAIL PROTECTED]">news:[EMAIL PROTECTED

Re: [PHP] passing arrays

2002-05-24 Thread Michael Virnstein
$myarray = unserialize(urldecode($_GET['myarray'])); or am i wrong? Regards Michael "Miguel Cruz" <[EMAIL PROTECTED]> schrieb im Newsbeitrag [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > On Thu, 23 May 2002, wm wrote: > > is there a way to pass arrays in forms or in the url? > > > > if i have $

Re: [PHP] passing arrays

2002-05-23 Thread Nathan
stead of _GET. - Original Message - From: "wm" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Thursday, May 23, 2002 1:49 PM Subject: [PHP] passing arrays hi, is there a way to pass arrays in forms or in the url? if i have $myarray=array("one",&qu

Re: [PHP] passing arrays

2002-05-23 Thread Miguel Cruz
On Thu, 23 May 2002, wm wrote: > is there a way to pass arrays in forms or in the url? > > if i have $myarray=array("one","two","three"); > > can i pass the whole array at once as opposed to having to pass each > individual element? Then in whatever.php: $myarray = unserialize($_GET['mya

Re: [PHP] passing arrays

2002-05-23 Thread Nathan
om: "wm" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Thursday, May 23, 2002 1:49 PM Subject: [PHP] passing arrays hi, is there a way to pass arrays in forms or in the url? if i have $myarray=array("one","two","three"); can i pass the

Re: [PHP] passing arrays

2002-05-23 Thread Pushkar Pradhan
Yes, You have to append the array name and values to the end of the url. You've to pass each element from html to php and vice versa, another method is using input hidden http://yoururl.com/index.php&myarray[]=one&myarray[]=two&myarray[]=three > hi, > > is there a way to pass arrays in forms or in

[PHP] passing arrays

2002-05-23 Thread wm
hi, is there a way to pass arrays in forms or in the url? if i have $myarray=array("one","two","three"); can i pass the whole array at once as opposed to having to pass each individual element? thanks. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.n

RE: [PHP] passing ARRAYs through GET strings

2002-05-18 Thread SP
Thanks Rick, that's what I thinking. Thought I was missing something. -Original Message- From: Richard Baskett [mailto:[EMAIL PROTECTED]] Sent: May 18, 2002 4:49 PM To: SP; PHP General Subject: Re: [PHP] passing ARRAYs through GET strings Well you can serialize an array usin

Re: [PHP] passing ARRAYs through GET strings

2002-05-18 Thread Richard Baskett
. - Napolean Hill > From: "SP" <[EMAIL PROTECTED]> > Date: Sat, 18 May 2002 16:35:00 -0400 > To: "Richard Baskett" <[EMAIL PROTECTED]>, <[EMAIL PROTECTED]>, "PHP > General" <[EMAIL PROTECTED]> > Subject: RE: [PHP] passing AR

RE: [PHP] passing ARRAYs through GET strings

2002-05-18 Thread SP
Rick, what exactly do you mean by using serialization without sessions? how do you do that? -Original Message- From: Richard Baskett [mailto:[EMAIL PROTECTED]] Sent: May 18, 2002 4:31 PM To: [EMAIL PROTECTED]; PHP General Subject: Re: [PHP] passing ARRAYs through GET strings Hey no

RE: [PHP] passing ARRAYs through GET strings

2002-05-18 Thread SP
Hey cool, didn't know that. -Original Message- From: Navid Y. [mailto:[EMAIL PROTECTED]] Sent: May 18, 2002 3:45 PM To: [EMAIL PROTECTED] Subject: RE: [PHP] passing ARRAYs through GET strings No need to serialize arrays in PHP 4.0. They work seamlessly, as if you've passed

Re: [PHP] passing ARRAYs through GET strings

2002-05-18 Thread Richard Baskett
rom: "Navid Y." <[EMAIL PROTECTED]> > Reply-To: <[EMAIL PROTECTED]> > Date: Sat, 18 May 2002 14:43:27 -0500 > To: "'PHP General'" <[EMAIL PROTECTED]> > Subject: RE: [PHP] passing ARRAYs through GET strings > > Well Rick, > > Let

RE: [PHP] passing ARRAYs through GET strings

2002-05-18 Thread Navid Y.
ECTED] Subject: RE: [PHP] passing ARRAYs through GET strings Okay let me clarify, if I had an array like this I would just use sessions this way: $myarray = array( array('1', '2'), array('3', '4') ); $_SESSION['myarray'] = serialize($mya

RE: [PHP] passing ARRAYs through GET strings

2002-05-18 Thread Navid Y.
e- From: Richard Baskett [mailto:[EMAIL PROTECTED]] Sent: Saturday, May 18, 2002 2:12 PM To: [EMAIL PROTECTED]; PHP General Subject: Re: [PHP] passing ARRAYs through GET strings Well what I normally do to pass very large arrays through strings.. when NOT using sessions, I use serialize, but it so

RE: [PHP] passing ARRAYs through GET strings

2002-05-18 Thread SP
ser goes to by doing this: $myarray = unserialize($_SESSION['myarray']); -Original Message- From: Navid Y. [mailto:[EMAIL PROTECTED]] Sent: May 18, 2002 2:52 PM To: [EMAIL PROTECTED] Subject: RE: [PHP] passing ARRAYs through GET strings Thanks SP and Richard, Well, I teste

Re: [PHP] passing ARRAYs through GET strings

2002-05-18 Thread Richard Baskett
"Navid Y." <[EMAIL PROTECTED]> > Reply-To: <[EMAIL PROTECTED]> > Date: Sat, 18 May 2002 13:51:38 -0500 > To: <[EMAIL PROTECTED]> > Subject: RE: [PHP] passing ARRAYs through GET strings > > Thanks SP and Richard, > > Well, I tested it and it works fine

RE: [PHP] passing ARRAYs through GET strings

2002-05-18 Thread Navid Y.
m: SP [mailto:[EMAIL PROTECTED]] Sent: Saturday, May 18, 2002 1:31 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: RE: [PHP] passing ARRAYs through GET strings Hi Navid Don't you have to serialize it to put it in sessions? -Original Message- From: Navid Y. [mailto:[EMAIL PROTECTED]]

Re: [PHP] passing ARRAYs through GET strings

2002-05-18 Thread Richard Baskett
CTED]> > Date: Sat, 18 May 2002 13:26:11 -0500 > To: <[EMAIL PROTECTED]> > Subject: [PHP] passing ARRAYs through GET strings > > Hello :) > > Can anyone suggest of another way, an easier way, to send arrays through > get strings, or through any other process, w

RE: [PHP] passing ARRAYs through GET strings

2002-05-18 Thread SP
Hi Navid Don't you have to serialize it to put it in sessions? -Original Message- From: Navid Y. [mailto:[EMAIL PROTECTED]] Sent: May 18, 2002 2:26 PM To: [EMAIL PROTECTED] Subject: [PHP] passing ARRAYs through GET strings Hello :) Can anyone suggest of another way, an easie

Re: [PHP] passing ARRAYs through GET strings

2002-05-18 Thread Richard Baskett
CTED]> > Reply-To: <[EMAIL PROTECTED]> > Date: Sat, 18 May 2002 13:26:11 -0500 > To: <[EMAIL PROTECTED]> > Subject: [PHP] passing ARRAYs through GET strings > > Hello :) > > Can anyone suggest of another way, an easier way, to send arrays through > get

[PHP] passing ARRAYs through GET strings

2002-05-18 Thread Navid Y.
Hello :) Can anyone suggest of another way, an easier way, to send arrays through get strings, or through any other process, without having to serializing it? For example, would it be better to use sessions in this case? Any help would be greatful, thanks. :) Navid -- PHP General Mailing L

RE: [PHP] Passing Arrays

2002-04-22 Thread Maxim Maletsky \(PHPBeginner.com\)
; PHP General (E-mail) Subject: Re: [PHP] Passing Arrays On Monday 22 April 2002 11:40 am, Boaz Yahav wrote: > Suppose i have a multiple select posted to a script by a form. now i > have to send this array again with a new form to a new script. >   > How do i do this? >   > t

Re: [PHP] Passing Arrays

2002-04-22 Thread Matt Williams
On Monday 22 April 2002 11:40 am, Boaz Yahav wrote: > Suppose i have a multiple select posted to a script by a form. > now i have to send this array again with a new form to a new > script. >   > How do i do this? >   > thanks >   > berber Hi Berber you could serialize the array into a hidden f

[PHP] Passing Arrays

2002-04-22 Thread Boaz Yahav
Suppose i have a multiple select posted to a script by a form. now i have to send this array again with a new form to a new script. How do i do this? thanks berber

[PHP] Passing arrays to other php routines in popup window

2001-09-14 Thread Gavin
I am using Apache with php version 4.0.4pl1. I am trying to display data in a popup window. I want to pass there variables, one string and two normal arrays. Both the $name and $data variables contain valid data in the dispData routine, however the $data2 array is always blank. ** $

Re: [PHP] passing arrays

2001-06-23 Thread Zak Greant
Jason Jacobs wrote: > Hi all. I'm trying to pass an array to another page, and I'm not having > luck. I thought maybe it would do something slick by passing it in the > url, but it doesn't. So, how can I pass the array? You can pass an array between pages by using the serialize() and u

Re: [PHP] passing arrays

2001-06-22 Thread Phillip Bow
You could use sessions, but it may be overkill for what you are trying to do. -- phill ""Jason Jacobs"" <[EMAIL PROTECTED]> wrote in message 001201c0fb50$6f895300$7feb1e18@superman">news:001201c0fb50$6f895300$7feb1e18@superman... Hi all. I'm trying to pass an array to another page, and I'm not h

[PHP] passing arrays

2001-06-22 Thread Jason Jacobs
Hi all.  I'm trying to pass an array to another page, and I'm not having luck.  I thought maybe it would do something slick by passing it in the url, but it doesn't.  So, how can I pass the array?  I've done it before by going through the array and making a hidden input field for each of the

RE: [PHP] Passing arrays from page to page

2001-04-25 Thread ..s.c.o.t.t.. [gts]
well, one idea is to serialize the array and put into a HIDDEN text field to be submitted with the FORM. or, with no form, try this: "doc.php?myarray=". htmlentities(serialize($array)); > -Original Message- > From: Clif [mailto:[EMAIL PROTECTED]] > Subject: [PHP]

[PHP] Passing arrays from page to page

2001-04-25 Thread Clif
I'm trying pass an array from one page to another. Page 1 is a form. Page 2 has the data sent by Page 1 available in $HTTP_POST_VARS. This is where I'm stuck: Page three needs access to those same variables in $HTTP_POST_VARS. Any help? -- PHP General Mailing List (http://www.php.net/) To uns

[PHP] Passing Arrays Between Pages Using Forms

2001-04-05 Thread Mike Gifford
Hello, I've currently got a list which is generated from a single database table: http://openconcept.ca/rabble/newsfeeds.phtml I can now select from this list and be presented with a more concenced list of links into which changes can be made and summaries added: http://openconce

Re: [PHP] Passing Arrays

2001-04-05 Thread Jordan Elver
Cheers, that works great. I tried using urlencode but that doens't work like it should in the manual. Thanks, Jord On Thursday 05 April 2001 14:41, you wrote: > You have to do this: > > $myarray = rawurlencode(serialize($myarray)); > > And then this on your other page: > > $myarray = unseriali

RE: [PHP] Passing Arrays

2001-04-05 Thread Rudolf Visagie
n_start() again, and can refer to $ix[0], $ix[1],.. $ix[$n] etc. Rudolf Visagie [EMAIL PROTECTED] -Original Message- From: Jordan Elver [mailto:[EMAIL PROTECTED]] Sent: 05 April 2001 02:56 To: PHP Database Mailing List; PHP General Mailing List Subject: [PHP] Passing Arrays Hi, How

[PHP] Passing Arrays

2001-04-05 Thread Jordan Elver
Hi, How can I pass an array between two pages. I've tried using serialize and unserialize. But it doen't return an array. When I use gettype() on it, it say's that the typ-e is boolean? Any ideas? Cheers, Jord -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL

[PHP] passing arrays through URLS

2001-02-18 Thread Jamie Smith
I need to pass a array through a url. Currently I'm assigning the array to the url like so http://localhost/dir/page.php?checkbox_array=$checkbox_array but when I want to sort through the array on the recieved page it is not possible because the array seems to have been replaced with the string

[PHP] passing arrays through URLS

2001-02-18 Thread Jamie Smith
I need to pass a array through a url. Currently I'm assigning the array to the url like so http://localhost/dir/page.php?checkbox_array=$checkbox_array but when I want to sort through the array on the recieved page it is not possible because the array seems to have been replaced with the string

Re: [PHP] Passing arrays as arguments to a method

2001-02-08 Thread Chris Lee
Ive seen posts like this before ( 'how do I pass arrays as arguments to functions?' ) this is quite simple, nothing at all has to be done. $val) echo "$pos : $val \n"; } } $arr[] = 'chris '; $arr[] = 'lee '; $arr[] = 'works for '; $arr[] = 'mediawaveonline.com '; $test = new test($

[PHP] Passing arrays as arguments to a method

2001-02-08 Thread rodrigo
Is it possible to pass arrays as arguments to class methods? If so, how? What is the proper syntax and things to look out for. Thanks in advanced. -- Ivan R. Quintero E.* (507)228-3477 Aptdo 1263 * (507)228-9105 Balboa, Ancon * 640-0370 Rep

Re: [PHP] passing arrays of objects

2001-02-01 Thread Teodor Cimpoesu
"Conover, Ryan" wrote: > > I was wondering if I can pass an array that has serialized objects to next > page via url encoding > > $foo //array with serialized objects in it > > with the following encoding > > something/something/foobar.php?foo=echo($foo) > > and be able too unserialize $fo

[PHP] passing arrays of objects

2001-02-01 Thread Conover, Ryan
I was wondering if I can pass an array that has serialized objects to next page via url encoding $foo //array with serialized objects in it with the following encoding something/something/foobar.php?foo=echo($foo) and be able too unserialize $foo on the next page(foovar.php) ryan -- PHP Ge

RE: [PHP] passing arrays via forms ..

2001-01-23 Thread Neil Kimber
serialise it using serialize() - see under chapter 12 of the PHP manual 'Miscellaneous functions' -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] Sent: 23 January 2001 12:42 To: PHP list Subject: [PHP] passing arrays via forms .. howdy again :) does an

[PHP] passing arrays via forms ..

2001-01-23 Thread hsmith
howdy again :) does anybody knwo how to pass an array via forms using something like where $client_services is an array ? Hetni -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the