Results 1 to 3 of 3

Thread: Ext.ux.form.FileUploadField in IE

  1. #1
    Sencha User
    Join Date
    Aug 2008
    Posts
    19

    Exclamation Ext.ux.form.FileUploadField in IE

    Hi all,
    Ext.ux.form.FileUploadField does not work in IE as it works in Firefox. IE does not have "files" object under "dom" file input object.
    This is my code:
    var fp = new Ext.ux.form.FileUploadField({ id: 'fileId' })
    ....
    var dom = Ext.get('fileId-file').dom;
    var name = fp.getValue();
    if(dom.files.length > 0){
    if (dom.files[0].fileSize > uploadSizeLimit) {
    toast('Exceeds the the upload file size limit (5M.', 'Error');
    return;
    }
    var data = dom.files[0].getAsBinary();
    }

    The problem is "dom.files" in undefinied in IE but it is definied in Firefox.
    Does anyone have this problem? Any solution will be greatly aapreciated.
    Thank you very much,
    Irina

  2. #2
    Sencha User
    Join Date
    Aug 2008
    Posts
    19

    Lightbulb Dom for file input does not have "files" object in IE

    Hi all,
    I figured out that dom for file input does not have "files" object in IE. So there is no way to check file size on the client side in IE. I have rewritten my code to check file size by server and send back an error if it exceeds the limit.

  3. #3
    Sencha User
    Join Date
    Aug 2008
    Posts
    19

    Question Uploading big file (more then 20MB) causes IE error.

    Hi all,
    I have to send a server request to check a file size because there is no way to check the file size in IE on the client side. If the file is about 10 MB, all works fine and my server responses with the message that the limit is exceeded. BUT if a file size is about 20MB, it hangs on the progress bar step just right away, and got me an error " syntax error ext-all-debug.js..."
    I tried to use try/catch, but it does not help. Any ides how to catch or prevent this.
    Thank you very much,
    Irina

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •