This is a set of tests, to confirm that AJAX Upload works with most options.

Test 1 - Default options

Inline "A" element as upload button

Test 2 - Huge button - Default options - addressing with #test2

"DIV" element as upload button. Fixed width and height.

Test 3 - Resize window and check 1 and 2 again

Test 4 - Check all options !!!

When alerted upload is disabled. Select Submit & Enable

Check with image and some other file

                 
var upload = new AjaxUpload(jQuery('#test4'), {
    action: 'upload-test.php',
    name: 'woohoo-custom-name',
    data: {
        'key1': "This data won't be sent, we will overwrite it."
    },
    autoSubmit: false,
    responseType: 'json',
    onChange: function(file, ext){
    },
    onSubmit: function(file, ext){
        // Allow only images. You should add security check on the server-side.
        if (ext && /^(jpg|png|jpeg|gif)$/i.test(ext)) {                            
            this.setData({
                'key1': 'This should be alerted',
                'key2': '...'
            });
        } else {
            alert('not image');
            return false;
        }                            
    },
    onComplete: function(file, response){
        this.disable();
        alert(response.post.key1);
    }
});
jQuery('#test4upload').click(function(){
    upload.submit();
    upload.enable();
    return false;
});

Test 5 - Return false in onChange and file values

Select

new AjaxUpload(document.getElementById('test5'),{
    onChange: function(file, ext){
        return false;
    }
});    

Test 6 - with jQuery UI dialog - onSubmit this.disable();

Button in jQuery dialog, using input[type=file]