AjaxUploader within jQuery dialog

  •  06-29-2009, 11:58 AM

    AjaxUploader within jQuery dialog


    ** Joyce from Live Support sent us here **

    Hi, we bought your AjaxUploader, which is fantastic, and we would like to use it within a jQuery dialog. The problem that we are facing is that there is no event triggered when clicking the browse button (The popup is shown correctly with all its content, but when we click on browse nothing happens). If we move the <CuteWebUI> tag outside of the div used as the dialog, everything is fine, but we want it in the dialog box!
     
    Here is the code :
     
    JavaScript (jQuery)
    1. $(document).ready(function() {   
    2.    bindAttachmentsButton("myContainer");   
    3. });   
    4.   
    5. function bindAttachmentsButton(container) {   
    6.     var popupContainer = $("div[id*='panPopupAttachments']", container.parent());   
    7.   
    8.         $(popupContainer).dialog("open");   
    9.     });   
    10.   
    11.     $(popupContainer).dialog({   
    12.         autoOpen: false,   
    13.         modal: true,   
    14.         closeOnEscape: true,   
    15.         width: 1000,   
    16.         buttons: {   
    17.             "Close"function() {   
    18.                 $(this).dialog("close");   
    19.                 $("select").show();   
    20.             }   
    21.         }   
    22.     });   
    23. }  
     
    ASPX
    1. <div id="panPopupAttachments" style="display : none;">   
    2.     <h2>Attachments for this Update</h2>   
    3.     <CuteWebUI:Uploader runat="server"    
    4.         ID="ajaxUploaderAttachments"  
    5.         InsertText="Browse"
    6.         OnFileUploaded="ajaxUploaderAttachments_FileUploaded"  
    7.         MultipleFilesUpload="true">   
    8.         <ValidateOption MaxSizeKB="2097151" />   
    9.     </CuteWebUI:Uploader>   
    10.     <asp:UpdatePanel runat="server" ID="updatePanelAttachments">   
    11.         <ContentTemplate>     
    12.             <asp:GridView runat="server" ID="gvAttachments" />    
    13.         </ContentTemplate>   
    14.     </asp:UpdatePanel>   
    15. </div>  
    Thank you for your help!
     
    Jeepi
View Complete Thread