Ive tested under FF 3.0.13 and it works as expected. However in IE 6.0.2900 (my intended intranet browser) the functions dont fire.
I dont get a script error, just nothing happens. I dont have this problem if I dont use a modal dialog.
I changed the auto setting for uploadify to true, and the upload begins automatically in both IE and FF, but that is not per design.
Any help?
Also, Ive noticed that if I call the dialog more than once, I have multiple upload buttons.
How can I cleanly reset the uploadify element before launching my dialog?
WinXP
Local - Dev Server
Uploadify 2.1
I call fnShowUpload() when I want to display the modal upload dialog. This is not done at document.ready, but at a click event.
- Code: Select all
function fnShowUpload(){
$("#dialogUpload").dialog({
bgiframe: true,
autoOpen: false,
height: 300,
width: 250,
modal: true,
buttons: {
'Upload Files': function() {
alert('upload'); //this fires
$("#multiUpload").uploadifyUpload(); //nothing happens
},
'Clear Queue': function() {
alert('clear'); //this fires
$("#multiUpload").uploadifyClearQueue(); //nothing happens
},
'Cancel': function() {
$(this).dialog('close');
}
},
close: function() {
}
});
$("#multiUpload").uploadify({
"uploader" : "<s:url value='/js/jquery/uploadify/uploadify.swf'/>",
"script" : "<s:url value='jsonUploadMultiple.action'/>",
"cancelImg" : "<s:url value='/js/jquery/uploadify/cancel.png'/>",
"folder" : "<s:url value='/documents'/>",
"multi" : true,
"auto" : false,
"scriptAccess" : "always"
});
$("#dialogUpload").dialog("open");
}
This is my dialog/uploadify markup.
- Code: Select all
<div id="dialogUpload" title="Upload New Files" style="display:none">
<input type="file" id="multiUpload" name="multiUpload"/>
</div>
Thanks for any help.
Sumit
