title: Blueimp Fileupload trigger submit button after a successful ajax request
body: <p>using blueimp's fileupload how do I trigger a fileupload submit after a successful ajax request?
  I tried to trigger the fileuploadsubmit but it says that data is undefined. 
  Below is the initial code:</p>
  
  <p><strong>HTML:</strong></p>
  
  <pre><code>&lt;form id="add-project-form" method="post" action="http://localhost/project/add/"&gt;
      &lt;p&gt;
          &lt;label for="project"&gt;Project Name:&lt;/label&gt;  
          &lt;input id="project" class="input-text" type="text" name="name" /&gt;
      &lt;/p&gt;
      &lt;p&gt;
          &lt;label for="overview"&gt;Project Overview:&lt;/label&gt; 
          &lt;input id="overview" class="input-text" type="text" name="overview" /&gt;
      &lt;/p&gt;
      &lt;p&gt;&lt;input type="submit" value="Add Project" /&gt;
  &lt;/form&gt;
  
  &lt;form id="logo-upload" method="post" action="http://localhost/project/upload/" enctype="multipart/form-data"&gt;
      &lt;p&gt;
          &lt;input type="file" name="logo" id="logo" /&gt;
      &lt;/p&gt;
  &lt;/form&gt;
  </code></pre>
  
  <p><strong>jQuery:</strong></p>
  
  <pre><code>$('#logo-upload').fileupload({
      dataType: 'json',
      maxNumberOfFiles: 1,
      autoUpload: false
  }).on('fileuploadsubmit', function(e, data) {
      console.log(data);
  });
  
  
  $(document).on("submit", "#add-project-form", function(e) {
      e.preventDefault();
  
      var data    = $(this).serialize();
      var url     = $(this).attr("action");
  
      $.ajax({
          url: url,
          data: data,
          type: "post",
          dataType: "json",
          success: function(response) {
              if( response &amp;&amp; response.location != undefined ) {
  
                  // I would want the upload to begin here 
  
              $('#logo-upload').fileupload().trigger('fileuploadsubmit'); 
              }
          }
      });
  });
  </code></pre>