Skip to content
Advertisement

Drag and drop an image from desktop to a web text editor (implementation in JavaScript)

I want to implement a web text editor able to recognize when the user drag a image file over it’s editing surface and it automa(gically) starts the upload and insert the image near the cursor position.

In other words I don’t want the user to do the usual “insert->image->browse->ok”.

At the moment I am not very good at JavaScript. I know jQuery but I have not a clear idea about how to implement this. I don’t know if there’s an event handler able to help me in this situation; if not then there should be I think or web apps would miss some kind of interactivity.

I’ve heard miracles about HTML5 could it help me?

I’ve seen such things in Google Wave but that surface doesn’t seem to be a form field… Google lab’s black magic I guess….

Advertisement

Answer

User contributions licensed under: CC BY-SA
6 People found this is helpful
Advertisement