Horje
Where to Drop - ondragover

The ondragover event specifies where the dragged data can be dropped.

By default, data/elements cannot be dropped in other elements. To allow a drop, we must prevent the default handling of the element.

This is done by calling the event.preventDefault() method for the ondragover event:


Example of Drop - ondragover

This is done by calling the event.preventDefault() method for the ondragover event:
index.html
Example: HTML
<script>
 event.preventDefault()
</script>

Output should be:

Example of Drop - ondragover





Category:
Web Tutorial
Sub Category:
HTML Drag and Drop API
Uploaded by:
Admin


Read Article
https://develop.horje.com/learn/1434/reference