From 913f444598e6b529f04324cf087eb31b53eabd8b Mon Sep 17 00:00:00 2001 From: Jordan Wright Date: Mon, 15 Feb 2016 12:18:21 -0600 Subject: [PATCH] Fixing results download in Firefox. Fixes #153 --- static/js/app/campaign_results.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/static/js/app/campaign_results.js b/static/js/app/campaign_results.js index efba5e8b..3c1fbc44 100644 --- a/static/js/app/campaign_results.js +++ b/static/js/app/campaign_results.js @@ -111,7 +111,9 @@ function exportAsCSV(scope) { var dlLink = document.createElement('a'); dlLink.href = csvURL; dlLink.setAttribute('download', scope + '.csv'); + document.body.appendChild(dlLink) dlLink.click(); + document.body.removeChild(dlLink) } $("#exportButton").html(exportHTML) }