2 // Initialize the jQuery File Upload widget:
3 $('#fileupload').fileupload();
5 // Load existing files:
6 $('#fileupload').each(function () {
8 $.getJSON(this.action, function (result) {
9 if (result && result.length) {
10 $(that).fileupload('option', 'done')
11 .call(that, null, {result: result});