title: Plupload multiple instances
body: <p>I'm trying to set up unknown number of plupload instances on page. I need to dynamically add more instances and remove and reset some of them. I have the general idea, but nothing works. </p>
  
  <p>One of my tries is on <a href="http://jsfiddle.net/gzuri/X65zF/" rel="nofollow">jsfiddle</a>.</p>
  
  <p>Thank you for all the help.</p>
  
  <p>Code:</p>
  
  <pre><code>var uploaders = new Array();
  
  initUploaders = function(uploaders) {
      console.log("initUploaders()");
      $(".gallery").each(function() {
          var el = $(this);
          var button = el.attr("id") + "_uploader";
          console.log("Init uploader id:" + el.attr("id"));
          var uploader = new plupload.Uploader({
              runtimes: 'gears,html5,flash,silverlight,browserplus',
              browse_button: button,
              max_file_size: '10mb',
              url: 'ModuleGallery/Upload/',
              flash_swf_url: 'http://static.srv42.net/plupload/js/plupload.flash.swf',
              silverlight_xap_url: 'http://static.srv42.net/plupload/js/plupload.silverlight.xap',
              filters: [
                  {
                  title: "Image files",
                  extensions: "jpg,gif,png"}
              ]
          });        
  
          uploader.bind('FilesAdded', function(up, files) {
              uploader.start();
          });
  
          uploader.init();    
          galleryUploaders.push(uploader);
      };
  
      initUploaders(uploaders);
  </code></pre>