• A

    (@arsilan)


    Hi, we have successfully modified the Link Template in WP Download Manager to disable the single file page link by using the [title] tag. Currently, when a user clicks on the file title, it no longer redirects to the single file page, as intended.

    However, we would like to enhance this functionality by making the file titles directly initiate the download when clicked, instead of opening any page. We need assistance in configuring the template to make the file title a direct download link.

    Below is the full code from the template we have edited so far:

    <!-- WPDM Link Template: Default Template -->

    <div class="link-template-default card mb-2">
    <div class="card-body">
    <div class="media">
    <div class="mr-3 img-48">[icon]</div>
    <div class="media-body">
    <h3 class="package-title">[title]</h3>
    <div class="text-muted text-small"><i class="fas fa-copy"></i> [file_count] [txt=file(s)] <i class="fas fa-hdd ml-3"></i> [file_size]</div>
    </div>
    <div class="ml-3">
    [download_link]
    </div>
    </div>
    </div>
    </div>

    Is there a shortcode or method to achieve the following functionality in WP Download Manager?

    We want the file title to directly initiate the download when clicked. If the user is not logged in, clicking the file title should redirect them to the login page instead of showing the single file page.

    Could you please let us know if there is a built-in shortcode or a recommended approach to implement this?

    Thank you!

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Plugin Support Nayeem Hyder

    (@nriddhi)

    Hello arsilan,

    Hope you are well. You can use simply use this <a href="[download_url]" class="btn btn-primary">[title]</a>
    or use this for locked packages/files, <a href="[download_url]" data-package='[ID]' class="wpdm-download-link wpdm-download-locked btn btn-primary"> [title]</a>
    Please kindly check and let me know, if you have any queries.

    Thank you and kind regards

Viewing 1 replies (of 1 total)
  • You must be logged in to reply to this topic.