First question here and I apologize in advance if my research wasnt thorough enough.
I am using PLupload to retrieve images from my server which it does fine, my problem is showing them in the order in which they were uploaded. The image order while retrieving is important as it is a fundamental part of the application.
Here is my code so far to retrieving:
ready: function() {
plupload = $("#uploader").plupload('getUploader');
var files = new Array();
$.get('data/funcs/retrieve.php', function(data) {
<?php foreach($images as $key => $val){ ?>
files.push('<?php echo $val; ?>');
<?php } ?>
files.forEach(function(entry) {
var img = new mOxie.Image();
var url = o.resolveUrl(entry);
img.onload = function() {
plupload.addFile(img.getAsBlob());
} //end image onload
img.load(url);
});
for(var i = 0, upPreviousSize = plupload.files.length - files.length, size = files.length; i < size; i++) {
files[i]["initialIndex"] = (i + upPreviousSize) * -1;
}
});
Any help will be greatly appreciated.