How to sort the uploaded files in blueimp jquery plugin

355 Views Asked by At

I'm using this great jquery plugin https://github.com/blueimp/jQuery-File-Upload to upload images in my website.

I use the default jquery plugin code to get the uploaded files (in the following way)

$j('#showUploadedImages').on('click', function() {
    $j.ajax({
        url: '/upload/server/php-general-images/',
        dataType: 'json',
        context: $j('#fileupload')[0],
        data: 'userID=' + $j('#userID').val()
    }).always(function () {
        $j(this).removeClass('fileupload-processing');
    }).done(function (result) {
        $j(this).fileupload('option', 'done')
        .call(this, $j.Event('done'), {result: result});
    });
});

This code sort the images without an order, I'd like to order the list by the date they were uploaded. Or by any other posible oder like the file name.

Is there a way to achieve this?

0

There are 0 best solutions below