title: Fullcalendar: How to remove event
body: <p>Thanks to another post here on StackOverflow, I added some code to my select: method that prevents users from adding an event on a date prior to NOW.</p>
  
  <p>The downside is that when they click on the empty time slot, and the system then complains (an alert message), the attempted event remains.  How do I get rid of it?  Thanks!</p>
  
  <p>Update:  Here's my code:</p>
  
  <pre><code>    select: function(start, end, jsEvent) {
  
          var check = start._d.toJSON().slice(0,10),
              today = new Date().toJSON().slice(0,10),
              m = moment(),
              url = "[redacted]",
              result = {};
              title = "Class",
              eventData = {
                  title: title,
                  start: start,
                  end: start.clone().add(2, 'hour'),
                  durationEditable: false,
                  instructorid: 123,
                  locationid: 234
              };
  
  
          if(check &lt; today) {
              alert("Cannot create an event before today.");
  
              $("#calendar").fullCalendar('removeEvents', function(eventObject) {
                  return true;
              });
  
          } else {
  
              $.ajax({ type: "post", url: url, data: JSON.stringify(eventData), dataType: 'JSON', contentType: "application/json", success: function(result) {
  
                  if ( result.SUCCESS == true ) {
                      $('#calendar').fullCalendar('renderEvent', eventData, true);
                      $('#calendar').fullCalendar('unselect');
  
                  } else {
  
                      alert(result.MESSAGE);
                  }
  
              }});
          }
      }
  </code></pre>