FurryGorilla
Technical User
Hi
I've set up a table on a page which has product information for each row in the table. Each table row has a select box which is named using
where $i is a number that is incremented on each loop.
This then generates a series of select boxes named item_no_0, item_no_1, etc depending on how many products are in the table.
The problem I'm having is being able to access the value that is chosen in each select box. I understand that there will be variables named $item_no_0, $item_no_1 when the form is submitted but how can I access these using the $i variable?
Any help would be much appreciated.
Chris
I've set up a table on a page which has product information for each row in the table. Each table row has a select box which is named using
Code:
<select name=\"item_no_$i\"/>
This then generates a series of select boxes named item_no_0, item_no_1, etc depending on how many products are in the table.
The problem I'm having is being able to access the value that is chosen in each select box. I understand that there will be variables named $item_no_0, $item_no_1 when the form is submitted but how can I access these using the $i variable?
Any help would be much appreciated.
Chris