summaryrefslogtreecommitdiffstats
path: root/mobile/android/geckoview/src/androidTest/assets/www/download.html
blob: 4f06323dc61332da536443c183de32d87d653023 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
<html>
  <head>
    <meta charset="utf-8" />
  </head>
  <body>
    <script>
      const blob = new Blob(["Downloaded Data"], { type: "text/plain" });
      const element = document.createElement("a");
      const uri = URL.createObjectURL(blob);
      element.href = uri;
      element.download = "download.txt";
      element.style.display = "none";
      document.body.appendChild(element);
      element.click();
      URL.revokeObjectURL(uri);
    </script>
  </body>
</html>