From: Artur Adib Date: Wed, 9 Nov 2011 01:02:28 +0000 (-0500) Subject: Replacing URL flag format X-Git-Url: https://git.parisson.com/?a=commitdiff_plain;h=f2d54d3207dac690396d278fcf651daa1cd4defb;p=pdf.js.git Replacing URL flag format --- diff --git a/extensions/firefox/components/pdfContentHandler.js b/extensions/firefox/components/pdfContentHandler.js index 444db1c..67459b7 100644 --- a/extensions/firefox/components/pdfContentHandler.js +++ b/extensions/firefox/components/pdfContentHandler.js @@ -52,7 +52,7 @@ pdfContentHandler.prototype = { } let targetUrl = aRequest.URI.spec; - if (targetUrl.indexOf('?pdfjs.action=download') >= 0) + if (targetUrl.indexOf('#pdfjs.action=download') >= 0) throw NS_ERROR_WONT_HANDLE_CONTENT; aRequest.cancel(Cr.NS_BINDING_ABORTED); diff --git a/web/viewer.js b/web/viewer.js index 1ab2c55..bfb3a43 100644 --- a/web/viewer.js +++ b/web/viewer.js @@ -139,7 +139,7 @@ var PDFView = { }, download: function pdfViewDownload() { - window.open(this.url + '?pdfjs.action=download', '_parent'); + window.open(this.url + '#pdfjs.action=download', '_parent'); }, navigateTo: function pdfViewNavigateTo(dest) {