I'm working on a chat application currently in beta phase (mypin.im) and would love you to help me out. My application works using websockets (framework: eninge.io) and I would like to know how I can externally drag an image using the HTML5 Drag and Drop API. I've researched and allot of the example don't work with external images (Dragging from PC to DIV). A good example of what I want is on the imgur drag and drop.
So my question is how to I drag and drop an external image and send it over WS. Would I mirror the image to a canvas and base64 it over to the other client?
Thanks :)
Asked
Active
Viewed 838 times
0

C1D
- 3,034
- 2
- 21
- 20
-
What are you having problems with? Can you get an example to drag an image to the page? Have you than tried to read that image to send it to the Web Socket? – epascarello Apr 12 '13 at 14:20
-
I don't know how to do the Drag and Drop with an External Image. I'm basically looking for what part of the API can do that or at least an example. – C1D Apr 12 '13 at 14:27
-
http://stackoverflow.com/questions/3694631/html5-drag-and-drop-between-windows – epascarello Apr 12 '13 at 14:36
-
@epascarello Thanks for that, I should of checked for a dupe comment. – C1D Apr 12 '13 at 14:41
1 Answers
0
I found my answer here (HTML5 drag and drop between windows), now I just have to integrate with websockets which I can do using this http://blog.marcon.me/post/31143865164/send-images-through-websockets!