Plupload - how to open more than one time and refresh the list?
js:
$(".butAnexarDoc").live("click开发者_JAVA百科", function(){
$("#anexarArquivos").plupload({
// General settings
runtimes : 'html5,html4',
url : 'js/plupload/examples/upload.php',
max_file_size : '1000mb',
max_file_count : 20, // user can add no more then 20 files at a time
chunk_size : '1mb',
unique_names : false,
multiple_queues : true
});
});
ok, first time work perfect, but if i click in a diferent place to open again, the list its not been reloaded.
its always the same, to reload the list i need to refresh the page.
how can i fix this ?
problem resolved:
$(".butAnexarDoc").live("click", function(){
$("#anexarArquivos").plupload({
// General settings
runtimes : 'html5,html4',
url : 'js/plupload/examples/upload.php',
max_file_size : '1000mb',
max_file_count : 20, // user can add no more then 20 files at a time
chunk_size : '1mb',
unique_names : false,
multiple_queues : true
});
// set to getUploader
var uploader = $('#anexarArquivos').plupload('getUploader');
// use splice to clean the list
uploader.splice();
});
精彩评论