title: manipulate dynamic input with php mysql and js
body: <p>I have a table named description:</p>
  
  <pre><code>CREATE TABLE description(
    word_id int(11),
    word varchar (50),
    PRIMARY KEY (word_id)
  );
  </code></pre>
  
  <p>and I try to get all word in this table and for every word I create a checkbox with value and id equal at a value of the word that I get from table description, 
   if the checkbox is checked, I save his value in var abcd.</p>
  
  <pre><code>&lt;?php
  ///connection
  $get_word = $bdd-&gt;query("SELECT * FROM description");
  while ($donnees = $get_word-&gt;fetch()) {
  ?&gt;
      &lt;input type="checkbox" id="&lt;?php $donnees["word"] ?&gt;" value="&lt;?php $donnees["word"] ?&gt;"&gt;
      &lt;br&gt;
  
      &lt;script&gt;
      $('#&lt;?php $donnees["word"] ?&gt;').on('change', function() {
          var abcd= this.checked ? this.value : '';
      });
      &lt;/script&gt; 
  &lt;?php
  }
  ?&gt;
  </code></pre>
  
  <p>Now, I want to create a button out of boocle while , if this button is clicked,it must give me the value of checkbox checked.</p>