title: How to insert radio button value into MySql
body: <p>anyone can help me with this
  thank you very much in advance</p>
  
  <p>This is my save.php file</p>
  
  <pre><code>&lt;?php
  
  include('db_connect.php');
  
  if (isset($_POST['Set1']))
  {
      $Set1 = $_POST['Set1'];
      mysql_query("INSERT INTO 'evaluation' (A1) VALUES ('$Set1')");
  }
  else if (isset($_POST['Set2']))
  {
      $Set2 = $_POST['Set2'];
      mysql_query("INSERT INTO 'evaluation' (A2) VALUES ('$Set2')");
  }
  else if (isset($_POST['Set3']))
  {
      $Set3 = $_POST['Set3'];
      mysql_query("INSERT INTO 'evaluation' (A3) VALUES ('$Set3')");
  }
  else if (isset($_POST['Set4']))
  {
      $Set4 = $_POST['Set4'];
      mysql_query("INSERT INTO 'evaluation' (A4) VALUES ('$Set4')");
  }
  //the code continue until A30..
  
  ?&gt;
  </code></pre>
  
  <p>this is my radiobutton file</p>
  
  <pre><code>   &lt;form action="save.php" method="post"&gt;
            &lt;h3 style="text-align:center;"&gt;B. Kerja Berpasukan&lt;/h3&gt;
            &lt;table class="table table-condensed" style="width:100%"&gt;
              &lt;thead&gt;
                &lt;tr&gt;
                  &lt;th&gt;Bil.&lt;/th&gt;
                  &lt;th id="th01"&gt;Kriteria&lt;/th&gt;
                  &lt;th id="th02"&gt;Skala Kompetensi&lt;/th&gt;
                &lt;/tr&gt;
              &lt;/thead&gt;
              &lt;tbody&gt;
                &lt;tr class="danger"&gt;
                  &lt;td&gt;1.&lt;/td&gt;
                  &lt;td&gt;Menunjukkan sifat-sifat bekerjasama seperti sedia 
                berkongsi maklumat dan kiraan yang telah
                      diperoleh/dilakukan&lt;/td&gt;
                  &lt;td&gt;
                      &lt;label class="radio-inline"&gt;
                        &lt;input id="r1" type="radio" name="Set6" value="1" 
  required/&gt;1
                      &lt;/label&gt;
                      &lt;label class="radio-inline"&gt;
                        &lt;input id="r2" type="radio" name="Set6" value="2" 
  required/&gt;2
                      &lt;/label&gt;
                      &lt;label class="radio-inline"&gt;
                        &lt;input id="r3" type="radio" name="Set6" value="3" 
  required/&gt;3
                      &lt;/label&gt;
                      &lt;label class="radio-inline"&gt;
                        &lt;input id="r4" type="radio" name="Set6" value="4"     
  required/&gt;4
                      &lt;/label&gt;
                      &lt;label class="radio-inline"&gt;
                        &lt;input id="r5" type="radio" name="Set6" value="5" 
  required/&gt;5
                      &lt;/label&gt;
                  &lt;/td&gt;
                &lt;/tr&gt;
                &lt;tr class="danger"&gt;
                  &lt;td&gt;2.&lt;/td&gt;
                  &lt;td&gt;Menunjukkan kesanggupan melaksanakan tugas dan 
               arahan/permintaan pegawai&lt;/td&gt;
                  &lt;td&gt;
                      &lt;label class="radio-inline"&gt;
                        &lt;input id="r1" type="radio" name="Set7" value="1" 
  required/&gt;1
                      &lt;/label&gt;
                      &lt;label class="radio-inline"&gt;
                        &lt;input id="r2" type="radio" name="Set7" value="2"  
  required/&gt;2
                      &lt;/label&gt;
                      &lt;label class="radio-inline"&gt;
                        &lt;input id="r3" type="radio" name="Set7" value="3" 
   required/&gt;3
                      &lt;/label&gt;
                      &lt;label class="radio-inline"&gt;
                        &lt;input id="r4" type="radio" name="Set7" value="4" 
   required/&gt;4
                      &lt;/label&gt;
                      &lt;label class="radio-inline"&gt;
                        &lt;input id="r5" type="radio" name="Set7" value="5" 
  required/&gt;5
                      &lt;/label&gt;
                  &lt;/td&gt;
                &lt;/tr&gt;
                &lt;tr class="danger"&gt;
                  &lt;td&gt;3.&lt;/td&gt;
                  &lt;td&gt;Sentiasa bertindak sebagai kumpulan seperti bersama 
                 menyediakan/membantu
                      membuat tugasan/aktiviti&lt;/td&gt;
                  &lt;td&gt;
                      &lt;label class="radio-inline"&gt;
                        &lt;input id="r1" type="radio" name="Set8" value="1" 
  required/&gt;1
                      &lt;/label&gt;
                      &lt;label class="radio-inline"&gt;
                        &lt;input id="r2" type="radio" name="Set8" value="2" 
  required/&gt;2
                      &lt;/label&gt;
                      &lt;label class="radio-inline"&gt;
                        &lt;input id="r3" type="radio" name="Set8" value="3" 
  required/&gt;3
                      &lt;/label&gt;
                      &lt;label class="radio-inline"&gt;
                        &lt;input id="r4" type="radio" name="Set8" value="4" 
  required/&gt;4
                      &lt;/label&gt;
                      &lt;label class="radio-inline"&gt;
                        &lt;input id="r5" type="radio" name="Set8" value="5" 
  required/&gt;5
                      &lt;/label&gt;
                  &lt;/td&gt;
                &lt;/tr&gt;
  
              &lt;/tbody&gt;
            &lt;/table&gt;
  </code></pre>
  
  <p>my database name is 'SPPI'
  table to save the radiobutton value is'evaluation'
  the table has a field from A1 to A30</p>