JavaScript Tutorial/Drag Drop/ondragenter — различия между версиями
Admin (обсуждение | вклад) м (1 версия) |
|
(нет различий)
|
Текущая версия на 11:24, 26 мая 2010
ondragenter event handler (IE)
<source lang="javascript">
<html>
<head> <title>System Drag And Drop Example</title> <script type="text/javascript"> function handleDragDropEvent(oEvent) { var oTextbox = document.getElementById("txt1"); oTextbox.value += oEvent.type + "\n"; } </script> </head> <body>
drag this text
<input type="text" ondragenter="handleDragDropEvent(event)" ondragover="handleDragDropEvent(event)" ondragleave="handleDragDropEvent(event)" ondrop="handleDragDropEvent(event)" /></p>
<textarea rows="10" cols="25" readonly="readonly" id="txt1"></textarea>
</body>
</html></source>