-1

On the left of my screen, i've a SVG world map (one path for each country). I control it with D3js On the right, i've a HTML list (ul) of people. I'm looking for a solution to drag the name of one people and drop it in one country (with a effect for the country when the element pass over it). I don't ask a complete code but just concept or method to focus my search.

Thanks a lot and have a good day !!

  • Here is the first google result for ["svg element hover"](http://www.petercollingridge.co.uk/data-visualisation/mouseover-effects-svgs). Look's like it's possible to bind javascript events to SVG-elements. Sounds like a fun project. Good luck. – Per Salbark Dec 01 '15 at 09:06
  • Try giving your shape a fill and listen to the drop event—it might work: http://stackoverflow.com/a/9956710/395910 – Terry Dec 01 '15 at 09:08
  • Thanks for your answers !! I've maybe a solution : interact.js. I've just make some (little) tests and the interaction between htm element and svg seems to be good.@Terry, i'm not sure that your link is the good, isn't it ? – David Naoures Dec 01 '15 at 12:05
  • I have done a similar code. The HTML5 standard drag and drop support was unreliable sometimes. jquery draggable worked just fine. – Peter Ambruzs Dec 01 '15 at 12:28
  • @Peter Thanks a lot ! I will test the Jquery draggable... and I keep in touch with you! – David Naoures Dec 01 '15 at 13:14

1 Answers1

0

OK with Jquery UI Draggable. Thanks a lot for your help !