WordPress.org

Forums

Download Monitor
[resolved] Link to download page (Download Monitor + Page Addon) (6 posts)

  1. ivanvolkov
    Member
    Posted 1 year ago #

    How to make [download] link to download page instead of direct downloading file?

    http://wordpress.org/plugins/download-monitor/

  2. Mike Jolley
    Member
    Plugin Contributor

    Posted 1 year ago #

    Make a new content template for your links (https://github.com/mikejolley/download-monitor/wiki/Content-Templates) but instead of using this for the link:

    <?php $dlm_download->the_download_link(); ?>

    Use the URL of your download page, replacing the ID portion with:

    <?php echo $dlm_download->id; ?>

  3. ivanvolkov
    Member
    Posted 1 year ago #

    Thanks!
    I replaced a code.
    But it still dont work like it should be.

    Example page:
    http://ivanvolkov.ru/detskaya-g-krasnoyarsk/

    Now link looks like:
    http://ivanvolkov.ru/detskaya-g-krasnoyarsk/67
    and go to nowhere.

    Link should be like this.
    http://ivanvolkov.ru/downloads/download-info/interior_scene/

    hmmm.

    Actually we need a download page permalink put to [download] template.

  4. Mike Jolley
    Member
    Plugin Contributor

    Posted 1 year ago #

    Ok, so use something like this:

    http://ivanvolkov.ru/downloads/download-info/<?php echo $dlm_download->post->post_name; ?>

  5. ivanvolkov
    Member
    Posted 1 year ago #

    mikejolley
    Oh, thanks!
    Now works!

  6. Mike Jolley
    Member
    Plugin Contributor

    Posted 1 year ago #

    Great :)

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Download Monitor
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic

Tags

No tags yet.