Drag and Drop in 2 Dimensions (DHMLGoodies)

I found an dhtmlgoodies js file, that really covers almost 100% my needs. All I want to ask is, how to make the drop function 2-dimensional. I mean, if there is enough space left from the right end of the one div to the end of the drop container, the selected div to go right from it and not down under.

its a long code

Here’s the jsfiddle :

http://jsfiddle.net/4A8rf/1/

Answer

Just float the dragable boxes:

http://jsfiddle.net/4A8rf/2/

.dragableBox{
    border:1px solid #000;
    /* Other properties ...*/
    float: left; /*<-- Add this */
}