download counter

Viewing 10 posts - 1 through 10 (of 10 total)
#30799

petryshakm
Member

Hello!

Is there any function which can show download counter? I need to show it in my wp theme files.

Thank you!

#30914

Shahjada
Keymaster

Use following code:
<?php echo get_post_meta(get_the_ID(), "__wpdm_download_count",true); ?>

#30916

petryshakm
Member

Thank you very much!
It works

#30919

Shahjada
Keymaster

You’re welcome. Please rate us 5* here https://wordpress.org/support/view/plugin-reviews/download-manager?rate=5#postform if you get some free moments, that will be very big support for us 🙂

#30921

petryshakm
Member

I left comment with 5 stars

#30924

petryshakm
Member

There is another problem. When I click on download link I get downloaded txt file with text inside – “You don’t have permission to download this file”

Everything was ok 2 days ago. I didn`t make any changes on site settings. Is this some typical error? How to fix it?

#30927

Tauhid
Member

Please try to deactivate and than activate the plugin, it will solve the issue.

#89541

I have the pro version and I tried your code, but it doesn’t work. Am I doing something wrong?

<?php echo get_post_meta(get_the_ID(14698), “__wpdm_download_count”,true); ?>

#89542

I found a workaround. I created a template

#89551

Shahjada
Keymaster

@ilocaleverywhere, yes, in pro version, you can handle it from the template. However, when you already know the package ID ( ex: 14698 ), the correct code is:

<?php echo get_post_meta( 14698 , “__wpdm_download_count”, true); ?>

For for pro support, please post here https://www.wpdownloadmanager.com/support/forum/download-manager-pro/ in future :).

Viewing 10 posts - 1 through 10 (of 10 total)

The topic ‘download counter’ is closed to new replies.