Forms and Arrays

From: Date: Fri, 28 Nov 2003 14:35:35 +0000
Subject: Forms and Arrays
Groups: php.general 
Request: Send a blank email to php-general+get-171277@lists.php.net to get a copy of this message
Hi List, I have a dynamically generated form with inputs with names that create arrays i.e.: <input name="fname[]"> <input name="flab[]"> <input name="fplc[]"> The extra bits for the inputs are omitted deliberately for this question but exists in the form i.e.: size, value, type. And these are repeated as many time as required. Thus they are generating arrays called: Fname0 Flab0 Fplc0 Fname1 Flab1 Fplc1 Fname2 Flab2 Fplc2 And so on as per the num of dynamically generated input lines for the form. My question is how can I treat each array separately and then move on to the next until end ? SO the output would be : fname0 = value flab0 = value fplc0 = value fname1 = value flab1 = value fplc1 = value fname2 = value flab2 = value fplc2 = value All keys / values are from $_POST via form button. I really hope I have been as clear as I can, but if you need more info them please email me. Thank you in advance for any help Dave C -------------------------------------------- EPH Group Ltd. Professional UK Based Web Hosting http://www.ephgroup.com In the UK? Call FREE: 0800 031 9190 Unlimited WebSpace, Unlimited Email Accounts, FREE Telephone Support, FREE co.uk domain name, FAST FRIENDLY SERVICE, UNIX & Windows accounts -------------------------------------------- --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.545 / Virus Database: 339 - Release Date: 27/11/2003

« previous php.general (#171277) next »