[newbie] Array form values.

From: Date: Mon, 05 Feb 2001 22:27:57 +0000
Subject: [newbie] Array form values.
Groups: php.general 
Request: Send a blank email to php-general+get-38324@lists.php.net to get a copy of this message
I have a form that is an extended version of this: <form> <input type="text" name="email[1]"> <input type="text" name="email[2]"> <input type="text" name="email[3]"> </form> Unfortunately, the email[1] part was generated using a variable in a loop. I have no idea how many of these fields there really will be each time this is done. I then need to turn around and, while processing the form, extract the values for each field in another loop. Trying to do echo $email[$i] doesn't seem to work, though. Is my entire logical approach wrong? Could it be something wrong with syntax? Is it not possible to use a variable as the inner part of an array like that? ooo, or best one to answer: does someone have a snippet of code doing what I want to do here, that I could learn from?

« previous php.general (#38324) next »