Dynamic radio buttons, different with unlimited names


I am doing a form that displays the questions and answers in a database and now I need to save the answers marked by the user.

I need a name for each RadioButton or select dropdown. PROBLEM: I combine php and html and i don't know how to pass the radiobutton's name or select drop down's name syntactically correct. The radiobuttons answers name are their ID to show all of them ( RADIO17, Radio18, RADIO19,RADIOX...), now I need to save the specific ID of the radiobutton checked by the user, for example RADIO19. Help please.

        <!--RADIO BUTTON--> 

                    <label class="desc"name="question" value=" <?php $row_questionset['QuestionIDFKPK'];?>">
                    <?php echo $row_questionset['QuestionValue']; ?>

                    <?php while ($row_Answer=mysql_fetch_array($AnswersValue)){ ?>
                    <fieldset class="radios">

                        <label class="label_radio">

                        **<input name="RADIO<?= $row_Answer['AnswerIDPK'] ?>" value="  <?= $ValueIDradio=$row_Answer['AnswerIDPK'] ?>" type="radio"  />**
                        <?php echo $row_Answer['AnswerValue']; ?>

                    <?php }  ?>

        <!--INSERTING ANSWERS-->



                    ??????? -> $name=$_POST['RADIO$row_Answer['AnswerIDPK']'];  

                                $query_AnswerSelected="SELECT * FROM tblanswer WHERE tblanswer.AnswerIDPK = '".$name."' ";
                                $AnswersValueSelected= mysql_query($query_AnswerSelected);
                                $Avalue= $row_AnswersValueSelected['AnswerValue'];
                                $useranswer= "INSERT INTO `nuevaspruebas`.`tbluseranswer` (`UserIDFKPK`, `AnswerIDFKPK`, `QuestionIDFK`, `AnswerValue`) VALUES ('$UserId','$name', '$QuestionID',  '$Avalue')";
                                <?= $nameradio=$row_Answer['AnswerIDPK'] ?>;
                                <!--INSERTING ANSWERS-->

            <!--RADIO BUTTON--> 

<?php } ?>

for the answers you will have to pass the question id in the name attrbuite and the value of the answer must be passed in the value attr

Run this code to get the idea:

        #you can loop through answers using
        foreach($_POST['question'] as $quesID => $ansID){
            //action goes here
        #view all the posted data
        echo "<pre>";
        echo "</pre>";
    $FirstQuestionID = 1;
    $SecondQuestionID = 2;
<form method=post action=<?=$_SERVER['PHP_SELF'];?> >
    first question
    <br />
    <input type="radio" name="question['<?=$FirstQuestionID;?>']" value='1' />
    <input type="radio" name="question['<?=$FirstQuestionID;?>']" value='2' />
    <input type="radio" name="question['<?=$FirstQuestionID;?>']" value='3' />
    <input type="radio" name="question['<?=$FirstQuestionID;?>']" value='4' />
    <br />
    second question
    <br />
    <input type="radio" name="question['<?=$SecondQuestionID;?>']" value='1' />
    <input type="radio" name="question['<?=$SecondQuestionID;?>']" value='2' />
    <input type="radio" name="question['<?=$SecondQuestionID;?>']" value='3' />
    <input type="radio" name="question['<?=$SecondQuestionID;?>']" value='4' />
    <br />
    <input type=submit name=submit value=submit />