I have a form that i created with Input. Here a sample of the form generated.
When the user hits the submit form button I am able to get the choices that they made from the $_POST array at indexes: Please_check_off_Business_Components_workedon , Please_check_off_Projects_workedon
But the radio buttons are being created by:
<strong>Activities - please check off activites performed by you</strong>
<?php
foreach($this->dataStore("activity") as $i=>$row) {
echo "<div>";
echo $row["activity"];
\koolreport\inputs\RadioList::create([
"name"=>"radio".$i,
"data"=>[
"Yes"=>1,
"No"=>2,
"n/a"=>0
],
"display"=>"horizontal"
]);
And in the $_POST they appear as radio0="0" radio1="0" radio2="0"
Thus I don't know what activity radio0 refers to since each survey is different. How can i find out what activity radio2 (for example) is? Instead of using radio.$i as the index, can I use "radio".$row->["activity]?