Issue Feature Closed

#83148Add Force download support to the FileDumpController

Frans Saris 11/28/17, 22:42 updated 03/04/20, 17:13

Description

The FileDumpController uses ResourceStorage::dumpFileContents() to dump the file. dumpFileContents() has a property so a Content-Disposition attachment header is sent, instead of inline.

But this option is currently not available when using the fildeDumpEID. A param &download=1 should be added to make this possible.

Reviews 0

No change resolves or names this issue in its commit message, and no comment links one.

History 6

  1. Frans Saris changed Complexity easy 11/28/17, 22:42

  2. Susanne Moog changed target version 09/06/18, 14:07

  3. Mathias Brodala commented 11/12/18, 11:04

    AFAIS this could be implemented using the FileDumpEIDHookInterface and manually calling $file->getStorage()->streamFile($file, true);.

  4. Frans Saris commented 11/12/18, 18:57

    Sure this is already possible by using the hook (like is done in ext:fal_securedownload).

    But problem is that the hook will break other hooks registered after your hook that forces the download. Like a download counter.

    That’s why it would be a nice addition if the core would support the stream option.

  5. Stefan Froemken commented 01/08/20, 11:48

    Hi. I just see that we have this line in TYPO3 9 now:

    return $file->getStorage()->streamFile($file);

    So this Issue can be closed now, right?

    Stefan

  6. Susanne Moog commented and changed status New Closed 03/04/20, 17:13

    Closed because of Stefans comment and no further feedback.