title: Update attendees response status - Google Calendar API (PHP)
body: <p>I've made a little application that uses Google Calendar API and Oauth2.
  Now I would like to allow user to answer at an event. This is my code:</p>
  
  <p>PHP</p>
  
  <pre><code>if(isset($_POST['submit'])){
  
      $eventSubmit = $service-&gt;events-&gt;get('primary', $_POST['eventID']);
      $attendeesSubmit=$eventSubmit-&gt;getAttendees();
  
      foreach ($attendees as $attendee) {
          $mailSubmit = $attendee-&gt;getEmail();
  
          if ($mailSubmit==$emailUser){
  
              if ($_POST['status']=='accepte'){
                 $attendee-&gt;setResponseStatus('accepted');
                 $service-&gt;events-&gt;update('primary', $_POST['eventID'], $eventSubmit);
  
              }
              if ($_POST['status']=='decline'){
                  $attendee-&gt;setResponseStatus('decline');
              }
  
          }
  
  }
  </code></pre>
  
  <p>HTML</p>
  
  <pre><code>    &lt;form method="post" action="index.php"&gt;
      &lt;input type="radio" name="status" id="accepte" value="accepte"&gt;Confirmer&lt;/input&gt;
      &lt;input type="radio" name="status" id="decline" value="decline"&gt;Décliner&lt;/input&gt;
      &lt;input type="hidden" name="eventID" value="&lt;?php echo htmlspecialchars($event['id']); ?&gt;"&gt;
      &lt;input type="submit" name="submit" value="OK"&gt;&lt;/br&gt;&lt;/br&gt;
  </code></pre>
  
  <p>But It doesn't work, user's reponse status doesn't change when I'm submit the form. What's the problem?</p>