javascript - HTML5 drop event child prevented -


i using html5 d&d. have 1 "parent" drop area, e.g. "parent". in parent drop childs, e.g. "child". each dropped child become dropped area, e.g. accept d&d events.

if dragging on "parent" area, highlighted, same "child" areas. face issue, "drop" event, fires "parent" area. if dragging on "child" area, "dragenter", "dragleave" work fine. "drop" event doesn't fire. instead, "parent" area fire it.

i resolve issue unbing in moment "drop" event "parent" area, it's not solution.

how fix in normal way?

ok, found have use

event.stoppropagation(); event.preventdefault(); 

in "drop" event. ensure it's binded not via jquery live.


Comments

Popular posts from this blog

ruby - When to use an ORM (Sequel, Datamapper, AR, etc.) vs. pure SQL for querying -

php - PHPDoc: @return void necessary? -

c++ - Convert big endian to little endian when reading from a binary file -