• Resolved hakpersson

    (@hakpersson)


    Would it be possible or in scope for the plugin to add possibility for more than one file per “download”? Perhaps this question have been asked before, but i could not seem to find anything among the current topics.

    [ddownload id=”XXX”] = File_A + File_B
    File Size = File_A + File_B

    In this scenario File_A starts to download, after finish (or concurrent) File_B starts.

    All the best!

    https://www.ads-software.com/plugins/delightful-downloads/

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author A5hleyRich

    (@a5hleyrich)

    Hi there,

    I’m afraid this feature falls outside the scope of this plugin. I may look at automatically compressing a group of files in the future but it’s not something I’m working on at the moment.

    As for starting another download after the previous ones starts, I’m not sure that it would even be possible, therefore that is something I don’t plan on including. If it were possible it would be a nightmare to try and get it working on every WordPress setup.

    The only thing you can do at the minute is manually compress the files before uploading them.

    Thanks,

    Ashley

    Thread Starter hakpersson

    (@hakpersson)

    Ok, no problems I understand. Since the site I′m currently building works around streaming (two) mp3-files this would mean using up more disk space than necessary.

    Regarding starting one download after the other I′ve solved this issue already on my site with a bit of jQuery. But as you say it might be difficult to get this working on all types of WordPress installs.

    Thanx! Below I′ve pasted in the snippets I use for download of File_A, then File_B. Someone might find it useful.

    jQuery

    if ($('.download').length) {
    
            $('.download').on('click', function () {
                var files = $(this).data('files').split(' ');
                multiDownload(files);
            });
    
        }

    .htaccess

    ##Force Download of files
    <FilesMatch "\.(?i:mp3)$">
      ForceType application/octet-stream
      Header set Content-Disposition attachment
    </FilesMatch>

    html/php

    <button class="download" data-files="File_A, File_B">Download files</button>

    Plugin Author A5hleyRich

    (@a5hleyrich)

    Excellent, thanks for sharing the code.

    Ashley

    Thread Starter hakpersson

    (@hakpersson)

    Sorry, forgot to paste in the link to the library by Sindre Sorhus I′m using. Here′s the link: https://github.com/sindresorhus/multi-download

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Multiple Files, Feature Request’ is closed to new replies.