Re: passing array from one page to itself?
| From: | Richard Baskett | Date: | Sat, 13 Apr 2002 00:34:15 +0000 |
| Subject: | Re: passing array from one page to itself? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-92833@lists.php.net to get a copy of this message | ||
If you are passing it through a posted form, just name your array variable
name[] So for example:
<input type="text" name="varname[]">
<input type="text" name="varname[]">
When it is posted php will realize it's an array and treat it such.
Or if you are just passing it through a link, you can do the same thing..
<a href="nextpage.php?varname[]=hey&varname[]=why">link</a>
Or you can serialize/deserialize.. Or you could use cookies, sessions, etc
etc etc..
If you give us a little more info on exactly what you are doing we could
probably help you with the best way of doing it :)
Cheers!
Rick
"The greatest trick the devil ever played was convincing the world he didn't
exist." - Unknown
> From: sundogcurt <sundogcurt@netscape.net>
> Date: Fri, 12 Apr 2002 17:14:14 -0700
> To: GENERAL PHP LIST <php-general@lists.php.net>
> Subject: [PHP] passing array from one page to itself?
>
> Hi again guys, I'm having trouble finding documentation on passing an
> array. Here is what I am doing.
>
> I have one page that calls itself, I want to pass an array that is setup
> the first time it's called to itself the second time it's called.
> I'm running out of both time AND hair (both of which are a rare comodoty
> these days).
>
> Any hint will be a HUGE help!
>
> Thanks in advance.
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>