How to stop a element from jumping to new page while still being able to download its contents?

后端 未结 0 1569
無奈伤痛
無奈伤痛 2020-12-21 17:05
function downloadStuff(theLink) {
  var link = document.createElement(\'a\');
  link.href = theLink
  link.download = \'Download\';
  document.body.appendChild(link)         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题