Viewing 7 replies - 1 through 7 (of 7 total)
  • Thread Starter Be Dark

    (@b_dark)

    Plugin Contributor Mike Jolley

    (@mikejolley)

    It cannot tell the file format from your link.

    You can turn off download forcing via a function in your theme’s functions.php. So if your download ID was 25 for this particular file, you’d do:

    add_filter( 'dlm_do_not_force', 'do_not_force_by_id' );
    
    function do_not_force_by_id( $do_not_force, $download ) {
    if ( $download->id == '25' ) return true;
    return $do_not_force;
    }

    To not force all downloads its easier:

    add_filter( 'dlm_do_not_force', '__return_true' );

    Thread Starter Be Dark

    (@b_dark)

    thnx a lot ?? can you add in next update this option on download files so we choose if we want with or without force the file?

    Hmm, if i add this in my functions.php

    add_filter( 'dlm_do_not_force', '__return_true' );

    This works fine with external URLs but my internal PDFs could not be opened in the browser anymore because the .htaccess in the folder “/dlm_uploads/.htaccess” denies all access

    Can i delete the .htaccess? Or what to do?

    Plugin Contributor Mike Jolley

    (@mikejolley)

    You can delete it, or you can upload the file elsewhere and link somewhere else.

    This file protects files from direct access, but still allows the plugin to ‘read’ it and serve it (this is the part you are turning off).

    is it possible to open external url in a new tab?

    Thread Starter Be Dark

    (@b_dark)

    its dosent working this code :/

    add_filter( 'dlm_do_not_force', 'do_not_force_by_id' );
    
    function do_not_force_by_id( $do_not_force, $download ) {
       if ( $download->id == '39444' )
          return true;
    
       return $do_not_force;
    }

    the code for force all downloads:

    add_filter( 'dlm_do_not_force', '__return_true' );

    working

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Problem with soundload url’ is closed to new replies.