title: file upload with formData returns undefined file array
body: <p>im getting undefined from print_r($_POST), it's posting on the same php page.</p>
  
  <pre><code>Array ( [file] =&gt; undefined )
  </code></pre>
  
  <p>Edited - added part where it calls the upload_banner function</p>
  
  <p><strong>HTML</strong></p>
  
  <pre><code>&lt;form enctype="multipart/form-data" id="banner_form" class="form-horizontal" role="form" action=""&gt;
    &lt;input type="hidden" name="MAX_FILE_SIZE" value="2000000"&gt;
    &lt;input id="file" name="file" type="file" class="filestyle" accept="image/jpeg,image/gif,image/png"&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p><strong>JS</strong></p>
  
  <pre><code>$('#submit_btn').click(function(e){
      e.preventDefault();
  
      var date = document.getElementById('datepicker').value;
      var title = document.getElementById('title').value;
      var content = document.getElementsByClassName('note-editable')[0];
  
      if(date == "" || title == "") {
        alert("Please fill in the required fields");
        return false;
      }
      else {
  
          var cfm = confirm("Confirm Submit Changes?");
          if(cfm === true)
          {
  
            var editarea = content.innerHTML;
  
            $.post ("functions/add_upcoming.php",{date: date,title: title,sm_content: editarea},
              function(data) {
            });
  
            upload_banner();
          }
          else
          {
            return false;
          }
        }
    });
  
  
  
  
  function upload_banner() {
      var form_data = new FormData($('#banner_form')[0]);
      form_data.append('file', $('input[type=file]')[0].files[0]);
  
        $.ajax({
          url: "upcomingevents.php?p=73",
          contentType: false,
          processData: false,
          dataType: 'json',
          data: form_data, 
          type: 'post',
          success: function(data) { },
          contentType: false,
          processData: false
      });
  }
  </code></pre>
  
  <p>json as datatype cause im returning arrays from php side, did not post additional code cause im already getting issue at the file upload part</p>
  
  <p><strong>PHP</strong></p>
  
  <pre><code>if(isset($_POST['file'])) {
    print_r($_POST);
    exit();
  }
  </code></pre>
  
  <p>am i doing anything wrong here? </p>