Changes to ViewerJS: -
// hide the document name as it will be visible in the panel title - this.download = function () { var documentUrl = url.split('#')[0]; documentUrl += '&contentDispositionType=attachment'; window.open(documentUrl, '_parent'); }; (in the compressed version it is: window.open(a+"&contentDispositionType=attachment","_parent")) // change the download url... otherwise the file will be shown inline