javascript - jQuery - using JS events like "dragover" -
i've got javascript function eventlistener `dragover. it looks this: document.getelementbyid("someid").addeventlistener("dragover", function(){ //do logic }, false); the thing - someid dynamic element - gets removed , added on page. after it's removed , added in, eventlistener no longer pickup dragover event. way know of how deal situation use jquery's .on() my problem: can't find dragover event under jquery api... exist? if not how can use in jquery? you can define customer drag event as, (function(jquery) { //defining drag event. jquery.fn.drag = function() { eventtype = arguments[0] || 'dragstart'; onevent = typeof arguments[1] == 'function' ? arguments[1] : function() { }; eventoption = arguments[2] || false; $(document).on('mouseover', $(this).selector, function() { if ($(this).hasclass(eventtype)) { return;