Skip to content
This repository was archived by the owner on Dec 20, 2023. It is now read-only.

Commit 3ddf105

Browse files
author
Barry de Graaff
authored
Merge pull request #202 from ibanezbass/patch-1
Patch 1
2 parents 0c384c6 + e6c18d0 commit 3ddf105

File tree

1 file changed

+2
-14
lines changed

1 file changed

+2
-14
lines changed

docconvert/zimlet/tk_barrydegraaff_docconvert/tk_barrydegraaff_docconvert.js

Lines changed: 2 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ docConvertZimlet.prototype.addDocConvertLink =
7373
function(attachment) {
7474
var html =
7575
"<a href='#' class='AttLink' style='text-decoration:underline;' " +
76-
"onClick=\"docConvertZimlet.prototype.saveAttachment('" + attachment.label + "','" + attachment.url + "')\">"+
76+
"onClick=\"docConvertZimlet.prototype.saveAttachment(&quot;" + attachment.label + "&quot;,&quot;" + attachment.url + "&quot;)\">"+
7777
"PDF" +
7878
"</a>";
7979

@@ -114,18 +114,6 @@ function(name, url) {
114114
};
115115

116116
docConvertZimlet.prototype.downloadBlob = function (filename, type, blob) {
117-
if (!window.navigator.msSaveOrOpenBlob)
118-
{
119-
var a = document.createElement("a");
120-
document.body.appendChild(a);
121-
a.style = "display: none";
122117
url = window.URL.createObjectURL(blob);
123-
a.href = url;
124-
a.download = filename;
125-
a.click();
126-
}
127-
else
128-
{
129-
window.navigator.msSaveOrOpenBlob(blob, filename);
130-
}
118+
window.open(url,'_blank');
131119
}

0 commit comments

Comments
 (0)