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

198
Views
el evento de caída no se activa

Editar: ¡Funciona para elementos html pero no para archivos!

Aquí está el código que tengo:

 <!DOCTYPE html> <html> <style> html, body { margin: 0; padding: 0; width: 100%; height: 100%; } body { display: flex; align-items: center; justify-content: center; } #drop_zone { border: 5px solid blue; width: 200px; height: 100px; } </style> <script> function dropHandler(ev) { console.log('File(s) dropped'); // Prevent default behavior (Prevent file from being opened) ev.preventDefault(); } function dragOverHandler(ev) { console.log('File(s) in drop zone'); // Prevent default behavior (Prevent file from being opened) ev.preventDefault(); } function dragEnterHandler(ev) { console.log('Entered drop zone'); // Prevent default behavior (Prevent file from being opened) ev.preventDefault(); } function dragLeaveHandler(ev) { console.log('Left drop zone'); // Prevent default behavior (Prevent file from being opened) ev.preventDefault(); } </script> <body> <div id="drop_zone" ondrop="dropHandler(event);" ondragover="dragOverHandler(event);" ondragenter="dragEnterHandler(event);" ondragleave="dragLeaveHandler(event)"> <p>Drag one or more files to this Drop Zone ...</p> </div> </body> </html>

Todos los demás eventos de caída se activan excepto ondrop .

ondrop no se activa

about 4 years ago · Juan Pablo Isaza
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!