Search code examples
file-uploadyiiyii-extensions

How can i hide the upload list in EAjaxUpload widget


I'm using EAjaxUpload extension to upload multiple files but I also want to use it to upload single ones.

How can I hide the upload list in this case?

Is there any way to configure that in the widget options?


Solution

  • Under config array, you can implement these function:

    'onSubmit' => "js:function(){
                        $('#uploadFile .qq-upload-list').html(''); // This will empty list
     }",
     'onComplete' => "js:function(id, fileName, responseJSON){
    
     }",
     'onProgress' => "js:function(id, fileName, loaded, total){
                    }",
     'onCancel' => "js:function(){
     }"