DragLib is very easy to use. Just call the method
DragObj.getInstance, like this:
DragObj.getInstance(oElement);
DragObj.getInstance(oElement, iConstraint);
If you have not already done so, download the package and save a duplicate copy.
This tutorial is divided into sections:
In order to minimize file size, whitespace has been removed from dragC.js.
Human readable source-code is available in the zip file (see drag.js).
Next in this tutorial: How To Make an Object Draggable