Topic: disable browse not working
I tried to disable the add button as per issue below, but it doesn't work.
https://github.com/moxiecode/plupload/issues/567
Firebug tells me that uploader is not defined.
Actually I am doing this to limit the total number of files added, as it seems that plupload only limits the number of files to be sent at ONE time.
The variable rest_img counts the number of remaining images as compared to the total number I stipulated.
Of course, the code below is part of the whole initialization of plupload, which does not seem necessary to repeat here, and it's working fine otherwise.
init : {
FileUploaded: function() {
rest_img = rest_img-1;
},
UploadComplete: function() {
// Called when all files are either uploaded or failed
if (rest_img == 0) {
//alert(rest_img);
uploader.disableBrowse();
}
}
}