Still having a form problem
| From: | Chris Payne | Date: | Mon, 30 May 2005 19:07:09 +0000 |
| Subject: | Still having a form problem | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-39568@lists.php.net to get a copy of this message | ||
Hi there everyone,
I'm still having problems with my form PHP data, I lost email for a couple
of days due to a server crash on my account so don't know if this was
answered or not (Sorry).
Basically, I have a form which populates 25 entries at a time from a MySQL
DB with PHP, you can select the product you want to order by entering a
value in the quantity box, if it was a single box it wouldn't be a problem,
but it's an array.
Now again, an array for the quantity is no problem at all, as I just use
<input name="quantity[]" type="text" class="style8"
id="quantity[]" value=""
size="5">
HOWEVER, I also need to transfer the $id (Named $id_new) from the database
in each quantity array at the same time so I can split each array into ID
and QUANTITY, this way I know which ID has which quantity, but this is what
has me stumped.
I tried with a HIDDEN field but of course that won't work, as there's no way
of aligning which ID goes with which quantity, so what I guess I need to
know, is how to amend $id_new with the quantity[] array.
Any help would be REALLY appreciated as this is really urgent.
Chris