Posted by Justin Case on 02/28/06 09:01
Hi, could you perhaps help me out with this, trying to manipulate data from
a form with multiple radio button groups.
I have a loop..
for ($i = 1; $i <= $num; $i++) {
...then trying to use $i like this but it doesn't work..
import_request_variables('p', 'p_');
$who = $p_radio$i;
...also tried this but no luck..
$who = $_POST['radio$i'];
Anyone? Here's a snippet of the form:
<div class="fileattachment" id="fileatt1">
<input type="file" name="fileattachment1">
<input type="radio" name="radio1" value="Bob" checked>Bob
<input type="radio" name="radio1" value="Joe">Joe
</div>
<div class="fileattachment" id="fileatt2">
<input type="file" name="fileattachment2">
<input type="radio" name="radio2" value="Bob" checked="checked">Bob
<input type="radio" name="radio2" value="Joe">Joe
</div>
Cheers.
Navigation:
[Reply to this message]
|