A small javascript library that handles drag n drop, letting you focus on your implementation details Aim to ease the difficulties in implementing drag n drop.
Still under development
Currently supports ie7+, chrome, firefox, opera and safari.
(function(d){
if(d.getElementById(id)) {
var js,
id = "dragdrop-js",
ref = d.getElementsByTagName('script')[0];
js = d.createElement("script");
js.id = id;
js.type = "text/javascript";
js.src = "/js/dragdrop/dragdrop.js";
js.async = false;
js. () {
if (js.readyState === "loaded" || js.readyState === "complete") {
js.
DRAGDROP. (dragElement) {
//your code to run on drag begin
};
DRAGDROP. (elementBelow, dragElement) {
//your code to run on drag
};
DRAGDROP. (dropElement, dragElement) {
//your code to run on drop
};
}
}
ref.parentNode.insertBefore(js, ref);
}
})(document)