Drag and drop file upload

Blocks ::: block_dndupload
Maintained by DavoDavo Smith
Drag and drop one or more files directly from your desktop into a Moodle course - if you have Moodle 2.3 or above, this functionality is already present
Latest release:
48 sites
20 downloads
7 fans
Current versions available: 2

This Moodle 1.9 / 2.x block allows you to drag files directly from your desktop onto a Moodle course. It should not be installed on a Moodle 2.3 site as it will clash with the built-in drag and drop upload.

It works with recent versions of Mozilla Firefox and Google Chrome, but not with Microsoft Internet Explorer (IE version 10 should have the required functionality). It has been tested with Windows and Linux and should work anywhere that the above browsers run.

Installation

  1. Install the block in the usual way
  2. Add the block to a course in the usual way
  3. Turn editing on (in the usual way) - the block does not show if editing is off
  4. Select a few files from your desktop and drag them onto a course section
Note - if it is not working, please check to see if there is a message in the block; it should warn you if your browser does not support the upload, or if you have AJAX course editing switched off.
The most up-to-date version of this module can always be found at: https://github.com/davosmith/moodle-block_dndupload
(I will not always update the version on Moodle.org when there are changes)

Screenshots

Screenshot #0

Contributors

Davo
Davo Smith (Lead maintainer)
Please login to view contributors details and/or to contact them

Comments RSS

Comments

  • Davo
    Tue, 29 May 2012, 3:56 PM
    Darcy - simple answer: do not use this block in 2.3. All the functionality of this block (plus a few small improvements) is directly available in Moodle 2.3, without any plugins, blocks or settings changes (except that d&d of URLs / text needs to be turned on under 'experimental settings'). I've been working with HQ to integrate my code directly.
  • Drew Smith
    Tue, 7 Aug 2012, 11:26 PM
    Hi Davo - A feature missing (or at least seems to be missing) in the 2.3 integration that IS available in the 2.2 plugin is the ability to drag course content (say a forum or quiz) to another location within the course, thus creating a "hyperlink" to the previous course content.

    For example, an instructor has a 2-week-long discussion; students the first week post a discussion, and the 2nd week they all respond. Thus, the same discussion would appear in 2 consecutive weeks. In your 2.2 version i can simply "drag" - not move - the discussion from week 1 to week 2, which then allows me to create a link back to the discussion.

    can't seem to make this happen utilizing the built-in drag/drop in 2.3, and I would really love that functionality.

    Thoughts?
  • Davo
    Thu, 9 Aug 2012, 2:06 AM
    Drew - Assuming you've enabled dragging and dropping of URLs and text under 'System admin > experimental features', then this should still work.
  • Drew Smith
    Thu, 9 Aug 2012, 2:38 AM
    @ Davo - indeed, it is enabled. i can drag external links (links from a different window) into the course content, however i cannot simply drag my content (such as a forum or quiz) on the topic outline page to create a link in a different week.

    The obvious workaround is to open the content i want to make a link for in a different window, then drag that link into my topic outline to the correct week. Not as convenient as drag/drop link right within the content outline window. Might be a bug worth investigating - but easy enough to work around. Thanks


  • Shirley VerStraete
    Thu, 16 Aug 2012, 1:36 AM
    When you say "It works with recent versions of Mozilla Firefox and Google Chrome, but not with Microsoft Internet Explorer" does that mean that the BUILT-IN drag and drop functionality also does not work with IE9.
    Thank you!
  • Davo
    Thu, 16 Aug 2012, 4:37 PM
    What do you mean by the 'built in' functionality. Do you mean the new functionality built in the Moodle 2.3 that replaces this block? If that is what you are asking, then the answer is yes - IE9 does not support drag and drop upload, so there is no way to make it work in this browser.
  • jen ol
    Fri, 17 Aug 2012, 4:11 PM
    Davo, thank you for the great plugin!

    Is there a way to change default Display option from Automatic( open file in same window) to In pop-up (open file in new window) for uploaded file.
    Thank you
  • Davo
    Fri, 17 Aug 2012, 4:17 PM
    it uses the global default for the file resource, which can be found via admin > plugins > activities > files
  • Jacques Monnard
    Thu, 23 Aug 2012, 5:21 PM
    Davo, thanks for the great block ! However, there is a problem with the latest version 2.2.4 of Moodle : the clock never stops spinning, and sometimes the progress bar just stops (the file is uploaded correctly, since reloading the page displays it). The same happens with Chrome and Firefox.
  • Davo
    Thu, 23 Aug 2012, 6:42 PM
    Jacques - If the problem in 2.2.4 is just a visual issue, rather than a real functionality problem, then I'm not going to look into it, as the block has now been replaced by core code in 2.3. It's not really worth my time to fix it as it is not obsolete.
  • Jacques Monnard
    Thu, 23 Aug 2012, 10:28 PM
    Davo, thanks for the quick answer. I think it's also a functionality problem. I just tested it again, and the file is not always uploaded (and you never know until you reload the page, since the clock never stops spinning).
  • Chris Lewis
    Fri, 24 Aug 2012, 9:14 AM
    Davo - we are also seeing this in 2.2.4 although, we have not had any problems getting the file uploaded. I do not think this was a problem in 2.2.3 but I am having a hard time recalling. The progress bar seems to be working for me.
  • Davo
    Sat, 25 Aug 2012, 12:08 AM
    Jacques, Chris - I've checked in a fix for this issue. Thanks for bringing it to my attention.
  • Jacques Monnard
    Mon, 27 Aug 2012, 1:51 PM
    Thanks a lot Davo, now it works perfectly again !
  • Chris Lewis
    Wed, 29 Aug 2012, 10:00 PM
    Davo - Thank you very much for fixing this! It is working great!
Please login to post comments