title: input type hidden does'nt post
body: <p>I have a system where people can indicate whether they are attending an event. There are several events to choose from. The events come from the database and have a unique id. Everything works fine, except the event and date can't be posted together.  Only when I make a checkbox of the date (or the event) everything neatly posted. A hidden textfield always posts the wrong date or event.</p>
  <pre><code>&lt;form action=&quot;insert.php&quot; method=&quot;post&quot;&gt;
  
  &lt;?php
  /* Attempt MySQL server connection. Assuming you are running MySQL
  server with default setting (user 'root' with no password) */
  $link = mysqli_connect(&quot;localhost&quot;, &quot;user&quot;, &quot;pass&quot;, &quot;db&quot;);
  
  // Check connection
  if($link === false){
      die(&quot;ERROR: Could not connect. &quot; . mysqli_connect_error());
  }
  
  $sql = &quot;SELECT * FROM events WHERE datum &gt;= CURDATE() AND toon &gt; 0 ORDER BY datum&quot;;
  if($result = mysqli_query($link, $sql)){
      if(mysqli_num_rows($result) &gt; 0){
  
          while($row = mysqli_fetch_array($result)){
                  
  echo &quot;&lt;input type=\&quot;radio\&quot; id=\&quot;datum\&quot; name=\&quot;datum\&quot; value=\&quot; &quot;; echo &quot;&quot; . $row['datum'] . &quot;\&quot; required&gt; &quot;;
  echo &quot;&lt;input type=\&quot;checkbox\&quot; id=\&quot;event\&quot; name=\&quot;event\&quot; value=\&quot; &quot;; echo &quot;&quot; . $row['event'] . &quot;\&quot;&gt; &quot;;
  print date('l d/m/Y', strtotime($row['datum']));
     
                
                echo &quot; &amp;#149; &quot;;
                if(strlen($row['url']) &gt; 0):
                echo &quot;  &lt;a href=\&quot; &quot; . $row['url'] . &quot; \&quot; target=\&quot;_blank\&quot;&gt;&quot;;
                endif;
                echo &quot;&quot; . $row['event'] . &quot;&lt;/a&gt;&quot;;
                echo &quot; &amp;#149; &quot; . $row['info'] . &quot;&quot;;
                echo &quot;&lt;br&gt;&quot;;
          }
  
          // Free result set
          mysqli_free_result($result);
      } else{
          echo &quot;No records matching your query were found.&quot;;
      }
  } else{
      echo &quot;ERROR: Could not able to execute $sql. &quot; . mysqli_error($link);
  }
   
  // Close connection
  mysqli_close($link);
  ?&gt;
  
  &lt;br&gt;&lt;br&gt;
  &lt;label for=&quot;naam&quot;&gt;Naam:&lt;/label&gt;
  &lt;input type=&quot;text&quot; name=&quot;naam&quot; id=&quot;naam&quot; placeholder=&quot;Jouw naam...&quot; required&gt;
  &lt;input type=&quot;hidden&quot; id=&quot;mee&quot; name=&quot;mee&quot; value=&quot;mee&quot;&gt;
  
  &lt;label for=&quot;opmerking&quot;&gt;Opmerking:&lt;/label&gt;
  &lt;input type=&quot;text&quot; name=&quot;opmerking&quot; id=&quot;opmerking&quot; placeholder=&quot;Eventuele opmerkingen...&quot;&gt;
  
  &lt;input type=&quot;hidden&quot; id=&quot;toon&quot; name=&quot;toon&quot; value=&quot;0&quot;&gt;
  
  
  &lt;input type=&quot;submit&quot; value=&quot;Ik ga mee!&quot; class=&quot;w3-button w3-black&quot;&gt;
  &lt;/form&gt;
  
  &lt;/div&gt;
  </code></pre>