Just a heads up: On March 24, 2025, starting at 4:30pm CDT / 21:30 UTC, the site will be undergoing scheduled maintenance for a few hours. During this time, the site might be unavailable for a short while. Thanks for your patience.
×Hi,
I would like to disable downloads for all attachments in Confluence server and have already followed the steps detailed here: https://confluence.atlassian.com/confkb/how-to-disable-attachment-downloads-215484007.html. It is not ideal as even administrators and uploaders will not be able to download their own attachments but that's the only solution we've found. However, we found out that users are still able to download files via the download button that's available when you preview a file. I'm aware that it's possible to disable the preview function altogether, but we need it.
Is it possible to disable only the download button? Will Confluence natively support attachment download controls in the future?
after many attempts, I got a solution:
extract mediaviewer.all.js from confluence-previews-7.0.11.jar, then changed
var tpl = handlebars_1.compile('\n <a role="button"\n tabindex="55"\n href="#"\n aria-label="{{label}}"\n class="cp-control-panel-download cp-icon"\n target="_blank"\n download>\n <span class="tooltip tooltip-n">{{label}}</span>\n </a>\n');
to
var tpl = handlebars_1.compile('');
finally, add mediaviewer.all.js into confluence-previews-7.0.11.jar
hope can help you.
tested this method on Confluence 6.15.1, it worked :D
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Is there a solution for this yet?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @jinpao,
I don't think complete solution for this.
Please refer below link, these may help
https://community.atlassian.com/t5/Confluence-questions/attachment-download-disable/qaq-p/153206
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.