$(function(){ var ul = $('#upload ul'); $('#drop a').click(function(){ // Simulate a click on the file input button // to show the file browser dialog $(this).parent().find('input').click(); }); // Initialize the jQuery File Upload plugin $('#upload').fileupload({ // This element will accept file drag/drop uploading dropZone: $('#drop'), // This function is called when a file is added to the queue; // either via the browse button, or via drag/drop: add: function (e, data) { var tpl = $('