title: Sending additional parameters with blueimp fileupload
body: <p>I'm using blueimp file-upload's capability to send additional parameters back to the server that are set inside <code>add</code>: </p>
  
  <pre><code>var simpleImport = false, replaceImport = false, mergeImport = false;   
  $uploadButton.fileupload({
              url: myURL,
              formData: { simple : simpleImport, replace : replaceImport, merge : mergeImport }, 
              add: function (e, data) {
                  var valid = true;
                  // validation logic
                  if (valid) {
                      if (condition №1) simpleImport = true;
                      else if (condition №2) replaceImport = true;
                      else if (condition №3) mergeImport = true;
                      data.submit();
                  }
              },
              done: function (e, data) {
                  if (data.result) {
                      oTable.ajax.reload();
                  }
              },
              fail: function (e, data) {
                  alert("shit happens");
              }
          });
  </code></pre>
  
  <p>On the server I read them in a such way:</p>
  
  <pre><code>var merge = Convert.ToBoolean(Context.HttpContext.Request.Form["merge"]);
  var simple = Convert.ToBoolean(Context.HttpContext.Request.Form["simple"]);
  var replace = Convert.ToBoolean(Context.HttpContext.Request.Form["replace"]);
  </code></pre>
  
  <p>But despite changing its values inside <code>add</code> I still got all of them equal to <code>false</code> in my handler. Is there any method to obtain proper values except using hidden inputs or I'm doing something entirely wrong?</p>