PHP - passing a variable from a repeated region?
Posted: Thu Apr 12, 2007 11:17 am
Hey, I need a little help here.
I'll try to explain what im trying to do as best as I can.
I have a repeated region with a 'Name' a 'ID' and a 'Submit' button
Repeated Region
------------------------------------------------
{Recordset1.Name}, {Recordset1.ID} | SUBMIT |
------------------------------------------------
so on my page I see every name next to every ID in my database and each one has their own submit button.
Now what I need to do is on Submit pass the specific ID of the row in the table for which the submit button was pressed.
For example if they scroll down to the 5 element in the repeated region (with ID 5) and they hit Submit I need to pass the number 5 to a function.
I understand that you cant call a php function from a button press so I have been trying to do this with the
if(isset($_POST['submit']))
{
// do whatever with the variable.
}
statement.
Does anyone know how I can do this properly?
THANKS!
I'll try to explain what im trying to do as best as I can.
I have a repeated region with a 'Name' a 'ID' and a 'Submit' button
Repeated Region
------------------------------------------------
{Recordset1.Name}, {Recordset1.ID} | SUBMIT |
------------------------------------------------
so on my page I see every name next to every ID in my database and each one has their own submit button.
Now what I need to do is on Submit pass the specific ID of the row in the table for which the submit button was pressed.
For example if they scroll down to the 5 element in the repeated region (with ID 5) and they hit Submit I need to pass the number 5 to a function.
I understand that you cant call a php function from a button press so I have been trying to do this with the
if(isset($_POST['submit']))
{
// do whatever with the variable.
}
statement.
Does anyone know how I can do this properly?
THANKS!