Ajax Upload popup window not showing

31 Views Asked by At

I am new to Ajax Upload and use http://valums.com/ajax-upload js file to cater for my upload file function. As i try to click the button for ajax upload...the pop up window to select file is not showing so i was unable to select file. Below is my button and code to trigger ajax upload.

<button class="pbutton btn-glossy-black" id="browseFile">Browse</button>


var upload = new AjaxUpload('browseFile', {
            action: jq_main_url + 'candidates/upload_attachment/' + main_folder_name,
            name: 'upload_file',
            data:{ 'countchecklist': 0},
            
            onComplete: function(file, response) {
                try {
                    var json = JSON.parse(response);
                    if(json.status == 'OK'){
                        alert('Complete');
                    } else {
                        core.jq_message(messageLevel, json.message);
                    }
                } catch(e){
                    core.jq_message(messageLevel, e.message);
                }
            }
        });
0

There are 0 best solutions below