Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

146
Views
¿Hay alguna forma de hacer que este botón de descarga funcione usando el enlace https?

Estoy tratando de descargar algo de otro sitio web, lo intenté pero no funcionó. por favor necesito ayuda aqui

 <a href="https://www.samanthaming.com/logo.png" class="text-1 text-uppercase" download> download here</a>
about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

Al principio, asegúrese de que el enlace de descarga sea válido. Ahora puede crear una función javascript personalizada para forzar la descarga desde un enlace externo.

 <script> function downloadForce(link){ var url = link.getAttribute("data-href"); var fileName = link.getAttribute("download"); link.innerText = "Downloading..."; var xhr = new XMLHttpRequest(); xhr.open("GET", url, true); xhr.responseType = "blob"; xhr.onload = function(){ var urlCreator = window.URL || window.webkitURL; var imageUrl = urlCreator.createObjectURL(this.response); var tag = document.createElement('a'); tag.href = imageUrl; tag.download = fileName; document.body.appendChild(tag); tag.click(); document.body.removeChild(tag); link.innerText="download here"; } xhr.send(); } </script> <a class="text-1 text-uppercase" href="#" data-href='https://i.imgur.com/U2KQsBD.jpeg' download="image.jpeg" onclick='downloadForce(this)'>download here</a>
about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!