Project:Private Upload
Version:5.x-1.0-beta6
Component:Code
Category:bug report
Priority:normal
Assigned:infernix
Status:closed (fixed)

Issue Summary

Hi,

When using the download_counter module together with Private Upload, the URL for file attachments loses the '/system' part, effectively linking the user directly to the (inaccessible) private path:

http://website.tld/files/private/filename.ext

Instead it should link to http://website.tld/system/files/private/filename.ext. I had a quick look at the download_counter code but couldn't find out why this is happening.

Any help would be greatly appreciated.

Thanks!

Comments

#1

Title:Conflict with Download_counter» Conflict with download_count
Assigned to:Anonymous» infernix
Status:active» needs review

I found a solution.

In download_count, edit download_count.module.

In the function theme_download_count_body, find:

$href = $file->fid ? file_create_url($file->filepath) : url(file_create_filename($file->filename, file_create_path()));

change this to:

$href = _private_upload_create_url($file); // this is the changed line

And it's fixed.

#2

Status:needs review» closed (fixed)
nobody click here