title: PHP don't get select info with $_POST
body: <p>I'm working on a webpage that generate an excel file, that I want to select the language I want between English and French. So, in that page, I have two <code>select</code> inputs, one of those it's the language selector.
  The other one it's on the trainer.</p>
  
  <p>I call them in php :</p>
  
  <pre><code>$formateur=$_POST['nomFormateur'];
  $query1="select * from formateur where formateurId=$formateur";
  $info=info_query($query1);
  $nomFormateur=$info['formateur'];
  
  $lang=$_POST['lang'];
  
  $date1=$_POST['date_debut'];
  $date2=$_POST['date_fin'];
  </code></pre>
  
  <p>When I select all what I want like : 
  <a href="https://i.stack.imgur.com/PFayY.png" rel="nofollow noreferrer">My option</a></p>
  
  <p>PHP, didn't take value of my second <code>select</code> (the language one) :</p>
  
  <pre><code>&lt;td&gt;
      &lt;select name="nomFormateur" id="nomFormateur" class="name"&gt;
          &lt;option value=""&gt;&lt;/option&gt;
          &lt;?php   
          $query="select * from formateur";
          $rows=get_array($query);
  
          foreach($rows as $value) {
              echo '&lt;option value='.$value['formateurId'].'&gt;'.$value['formateur'].'&lt;/option&gt;';    
          }
          ?&gt;
      &lt;/select&gt;
  &lt;/td&gt;
  &lt;td align="left"&gt;&lt;font size="2" color="gray"&gt;Langue :&lt;/font&gt;&lt;/td&gt;
  &lt;td&gt;
      &lt;select name="lang" id="lang" onChange="name_click()"&gt;
          &lt;option value="0"&gt;-----&lt;/option&gt;
          &lt;option value="1"&gt;Anglais&lt;/option&gt;
          &lt;option value="2"&gt;Francais&lt;/option&gt;
      &lt;/select&gt;
  &lt;/td&gt;
  </code></pre>
  
  <p>When my Excel file open, I saw the good trainer, the good date, but the language it's still on English, that i choose, nothing, English or french. But I want that if I choose english (value 1), they show in english, but if I choose French (value 2), it's in french, not english.</p>
  
  <p>It's the only think that's not working. I do two different call in mysql to bring the excel in english or in french, in regard of this <code>&lt;select&gt;</code></p>
  
  <p>I try with Javascript and it's show me the good answer that I passed in an input and in an alert when I tested, but still not able to get the information in php</p>
  
  <p>Javascript function :</p>
  
  <pre><code>function name_click(){
      var value_select = document.getElementById("lang").value;
      document.getElementById("my_var").value=value_select;
  }
  </code></pre>
  
  <p>Can someone can help me?</p>