Monday, June 3, 2024
 Popular · Latest · Hot · Upcoming
155
rated 0 times [  157] [ 2]  / answers: 1 / hits: 23946  / 8 Years ago, tue, august 2, 2016, 12:00:00

According to caniuse the download attribute of <a> element is supported at Microsoft Edge build 10547+, but not IE or Safari.



How to download a file object without using <a> element with download attribute set or a server?


More From » html

 Answers
8

There are a number of ways of triggering a download. Following are a few:



Use a form:



<form method=get action=mydoc.doc>
<button type=submit>Download</button>
</form>


Use javascript:



<button type=submit onclick=window.open('mydoc.doc')>Download</button>

[#61181] Friday, July 29, 2016, 8 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
devane

Total Points: 451
Total Questions: 88
Total Answers: 100

Location: India
Member since Wed, Aug 26, 2020
4 Years ago
;