August 1999
Intermediate to advanced
1488 pages
72h 53m
English
onDragDrop="command"
The onDragDrop event handler of a property of a Window object is fired when the user drops an object, such as a file, on that particular window instance. Care should be taken when using this event handler, because it is possible to get into an infinite loop when using other event handlers such as onFocus and onBlur.
In Listing 7.556, if you try to drop a new file on to the browser when this page is loaded, you will be asked to confirm this operation. If you accept, the page will load. If you cancel, the page will not be loaded.
<html> <body onDragDrop='return(confirm("Are you sure you want to continue?"))'> ... |
Read now
Unlock full access