Check my fiddle from this thread: Draw a line connecting two clicked div columns
The layout is different, but basically the idea is to create invisible divs between the boxes and add corresponding borders with jQuery (the answer is only HTML and CSS)