1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Browser Issue Attachments freeze on upload

Discussion in 'Resolved Bug Reports' started by CyberAP, Aug 13, 2013.

  1. CyberAP

    CyberAP Well-Known Member

    I've been hundreds of times in this situation but I don't know the exact steps to reproduce it.
    The problem is when you upload attachments one by one it can somehow freeze. That means that you still can upload them but they won't show up in the attachments list (but in fact they are already uploaded). The upload overlay also won't close by itself, you have to click 'Cancel'. The only thing you are left to do is to create a thread (or to post a message) in order to see them.
    I am using default uploader, however I have Flash installed with FlashControl but XenForo still won't allow me to use flash uploader. Browser: Google Chrome 28 on Win 8.
     
  2. Mike

    Mike XenForo Developer Staff Member

    It's not something I've been able to reproduce. Anyone else?

    It sounds like some sort of JS error or failure. Are there any error logs in the console? Having the network tab open may help give us some more information if it happens (but that would need to be done before it happens).
     
  3. JulianD

    JulianD Well-Known Member

    I have never experienced something like this. The javascript must be failing at some point.
     
  4. CyberAP

    CyberAP Well-Known Member

    Just tried to upload an image. Here is what I've got in console:

    Code:
    object[type$="x-shockwave-flash"]:not([classid]),object[type$="futuresplash"]:not([classid]),embed[type$="x-shockwave-flash"],embed[type$="futuresplash"]{display:none !important}{"attachment_id":54154,"attach_date":1376479969,"filename":"promo-big.png","thumbnailUrl":"data\/attachments\/54\/54155-ab6393c81aa8b2947bd8745ff371c602.jpg","deleteUrl":"attachments\/promo-big-png.54154\/delete?temp_hash=dc5290797adc6784ac0a95857be08551","viewUrl":"attachments\/promo-big-png.54154\/?temp_hash=dc5290797adc6784ac0a95857be08551","templateHtml":"\n\n<li id=\"attachment54154\"\n\tclass=\"AttachedFile AttachedImage secondaryContent\">\n\n\t<div class=\"Thumbnail\">\n\t\t\n\t\t\t<a href=\"attachments\/promo-big-png.54154\/?temp_hash=dc5290797adc6784ac0a95857be08551\" target=\"_blank\"\n\t\t\t\tdata-attachmentId=\"54154\"\n\t\t\t\tclass=\"_not_LbTrigger\" data-href=\"misc\/lightbox\"><img\n\t\t\t\tsrc=\"data\/attachments\/54\/54155-ab6393c81aa8b2947bd8745ff371c602.jpg\" alt=\"promo-big.png\"\n\t\t\t\tclass=\"_not_LbImage\" data-src=\"attachments\/promo-big-png.54154\/?embedded=1&amp;temp_hash=dc5290797adc6784ac0a95857be08551\" \/><\/a>\n\t\t\n\t<\/div>\n\n\t<div class=\"AttachmentText\">\n\t\t<div class=\"Filename\"><a href=\"attachments\/promo-big-png.54154\/?temp_hash=dc5290797adc6784ac0a95857be08551\" target=\"_blank\">promo-big.png<\/a><\/div>\n\t\n\t\t\n\t\t\t<noscript>\n\t\t\t\t<a href=\"attachments\/promo-big-png.54154\/delete?temp_hash=dc5290797adc6784ac0a95857be08551\" target=\"_blank\" class=\"button Smallbutton\">Delete<\/a>\n\t\t\t<\/noscript>\n\t\t\t\n\t\t\t\n\t\t\t\t<div class=\"label\">Insert:<\/div>\n\t\t\t\n\t\t\t\n\t\t\t<div class=\"controls\">\t\t\t\t\n\t\t\t\t<input type=\"button\" value=\"Delete\" class=\"button smallButton AttachmentDeleter\" data-href=\"attachments\/promo-big-png.54154\/delete?temp_hash=dc5290797adc6784ac0a95857be08551\" \/>\n\t\t\t\n\t\t\t\t\n\t\t\t\t\t<input type=\"button\" name=\"thumb\" value=\"Thumbnail\" class=\"button smallButton AttachmentInserter\" \/>\n\t\t\t\t\t<input type=\"button\" name=\"image\" value=\"Full Image\" class=\"button smallButton AttachmentInserter\" \/>\n\t\t\t\t\n\t\t\t<\/div>\n\t\t\n\n\t<\/div>\n\t\n<\/li>","message":"Upload completed successfully","key":"","_visitor_conversationsUnread":"0","_visitor_alertsUnread":"0"} xenforo.js?_v=cdb2cdda:302
    (anonymous function)
     

    Attached Files:

  5. CyberAP

    CyberAP Well-Known Member

    I think it still tries to use Flash uploader though it's blocked.
     
  6. Brogan

    Brogan XenForo Moderator Staff Member

    Do you have any extensions installed in Chrome?
     
  7. CyberAP

    CyberAP Well-Known Member

    Link in the first post.
     
  8. Mike

    Mike XenForo Developer Staff Member

    Part of that is the actual content being returned, but at the beginning there's a bunch of CSS added to JSON results. I think it's one of your extensions manipulating the request content incorrectly.
     
  9. Mike

    Mike XenForo Developer Staff Member

    This part specifically:
    Code:
    object[type$="x-shockwave-flash"]:not([classid]),object[type$="futuresplash"]:not([classid]),embed[type$="x-shockwave-flash"],embed[type$="futuresplash"]{display:none !important}
    That seems to fit being from your selective Flash disabling extensions.
     
  10. CyberAP

    CyberAP Well-Known Member

    That's strange. It doesn't matter if Flash is blocked or not by this plugin — this issue occurs in both situations. However if I disable it uploading works fine. But I can't get rid of this addon, I use it on every site. And it's actually the first site that was broken by this addon.
     
  11. Mike

    Mike XenForo Developer Staff Member

    It looks like they're mostly just hiding Flash output by adding CSS. Looks like there might be a situation where it adds the CSS incorrectly (I believe we return the output here in text/plain for technical reasons).
     
  12. CyberAP

    CyberAP Well-Known Member

    The bug still occurs. Both for html or flash-based upload. This could be fixed with a use of HTML5 File API, more specifically → HTML5 Multiple file upload. I know IE<10 doesn't support it, but they could have a flash fallback.
    Or you can use this plugin, it provides support even for IE7: http://fineuploader.com/
     

Share This Page