Moodle
  1. Moodle
  2. MDL-31639

Drag and Drop file upload is shown as being available on browsers that are not compatible

    Details

    • Affected Branches:
      MOODLE_23_STABLE
    • Rank:
      38209

      Description

      While testing MDL-31112 I tried it under chrome, which shows that drag and drop is available, but when trying to drag and drop a file, it didn't work

        Issue Links

          Activity

          Hide
          Davo Smith added a comment -

          I assume I am OK to assign this to myself to get on with fixing this issue?

          (If there are any other drag & drop related issues that I've missed, could you assign them to me as well?)

          Show
          Davo Smith added a comment - I assume I am OK to assign this to myself to get on with fixing this issue? (If there are any other drag & drop related issues that I've missed, could you assign them to me as well?)
          Hide
          Rajesh Taneja added a comment -

          Thanks Davo.

          Show
          Rajesh Taneja added a comment - Thanks Davo.
          Hide
          Davo Smith added a comment -

          Could you confirm this is an issue in 2.2 stable - the message should only be appearing in 2.3 dev, as drag and drop upload is unavailable in 2.2.

          Also, the text is coded not to appear in unsupported browsers (and certainly works in Chrome, as that is my primary development browser).

          Could you let me know exactly what browser (and version) / OS combination you are using and exactly what happens if you try to drag / drop in this situation?

          Show
          Davo Smith added a comment - Could you confirm this is an issue in 2.2 stable - the message should only be appearing in 2.3 dev, as drag and drop upload is unavailable in 2.2. Also, the text is coded not to appear in unsupported browsers (and certainly works in Chrome, as that is my primary development browser). Could you let me know exactly what browser (and version) / OS combination you are using and exactly what happens if you try to drag / drop in this situation?
          Hide
          Jason Fowler added a comment -

          Sorry, yes, it's 2.3 only, Dan P observed as I tested it... Ubuntu 10.04.3 Chrome 17.0.963.46

          Show
          Jason Fowler added a comment - Sorry, yes, it's 2.3 only, Dan P observed as I tested it... Ubuntu 10.04.3 Chrome 17.0.963.46
          Hide
          Dan Poltawski added a comment -

          Davo the weird thing is that it seems like the 'drag and drop available' message is there, but when using the script debugger with breakpoints I couldn't find the initialisation of dnd being triggered..

          Show
          Dan Poltawski added a comment - Davo the weird thing is that it seems like the 'drag and drop available' message is there, but when using the script debugger with breakpoints I couldn't find the initialisation of dnd being triggered..
          Hide
          Davo Smith added a comment - - edited

          Are there any javascript errors appearing?
          Is there something going wrong with the initial hiding of the message (it should be set to 'display:none')?

          Either way, my dev box is Ubuntu 11.10, with both Chromium 17.0.924.0 and Chrome 17.0.963.46 (which makes me realise that I forgot to reenable the daily builds of Chromium dev when I upgraded last October). Drag and drop is working perfectly with both browsers (and FF, last time I tested). I do need to clear the Moodle cache and my browser cache from time to time though, to make sure the latest javascript is loaded.

          Show
          Davo Smith added a comment - - edited Are there any javascript errors appearing? Is there something going wrong with the initial hiding of the message (it should be set to 'display:none')? Either way, my dev box is Ubuntu 11.10, with both Chromium 17.0.924.0 and Chrome 17.0.963.46 (which makes me realise that I forgot to reenable the daily builds of Chromium dev when I upgraded last October). Drag and drop is working perfectly with both browsers (and FF, last time I tested). I do need to clear the Moodle cache and my browser cache from time to time though, to make sure the latest javascript is loaded.
          Hide
          Davo Smith added a comment -

          Jason - is this still happening or is the issue now resolved? I have not been able to reproduce this myself.

          Show
          Davo Smith added a comment - Jason - is this still happening or is the issue now resolved? I have not been able to reproduce this myself.
          Hide
          Dan Poltawski added a comment -

          Hi Davo,

          Jason is away this week but it was still happening before he left.

          Show
          Dan Poltawski added a comment - Hi Davo, Jason is away this week but it was still happening before he left.
          Hide
          Davo Smith added a comment -

          Jason, would you be able to grab the latest Moodle 2.3 dev from git, make sure you're still getting the same problems (after clearing the Moodle caches, your browser cache, etc.), then replace 'lib/form/dndupload.js' with the version I've just attached (and clear all caches again).

          It includes lots of javascript 'alert' boxes which may shed some light on where things are going wrong.

          Please could you let me know which alert boxes pop up and I'll try to see if that helps (there should be alerts during the form initialisation and more when you drop a file onto the filemanager element - unfortunately alerts when you are dragging files would interrupt the drag and prevent the drop from ever happening).

          Show
          Davo Smith added a comment - Jason, would you be able to grab the latest Moodle 2.3 dev from git, make sure you're still getting the same problems (after clearing the Moodle caches, your browser cache, etc.), then replace 'lib/form/dndupload.js' with the version I've just attached (and clear all caches again). It includes lots of javascript 'alert' boxes which may shed some light on where things are going wrong. Please could you let me know which alert boxes pop up and I'll try to see if that helps (there should be alerts during the form initialisation and more when you drop a file onto the filemanager element - unfortunately alerts when you are dragging files would interrupt the drag and prevent the drop from ever happening).
          Hide
          Jason Fowler added a comment -

          Sorry Davo, I've been on holiday in New Zealand, and will be back in the office on Wednesday Perth time, I will go over this all then.

          Show
          Jason Fowler added a comment - Sorry Davo, I've been on holiday in New Zealand, and will be back in the office on Wednesday Perth time, I will go over this all then.
          Hide
          Jason Fowler added a comment -

          Davo, yeah the problem existed I uploaded that file, and afterwards I got a tonne of alerts telling me what was happening, and it's all working now

          Show
          Jason Fowler added a comment - Davo, yeah the problem existed I uploaded that file, and afterwards I got a tonne of alerts telling me what was happening, and it's all working now
          Hide
          Davo Smith added a comment -

          Does it now work with the standard code? The attached code was identical, apart from the alert messages. If it does work with the standard code, can we close this issue?

          Show
          Davo Smith added a comment - Does it now work with the standard code? The attached code was identical, apart from the alert messages. If it does work with the standard code, can we close this issue?

            People

            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: