开发者

Jquery sortable, but from left <-> right and not up <-> down

I have looked around and i wast able to find a way so sort div elements from left to right and right to left.

What i am doing, is i am creating a website where a user can move navigation pane either to the right or do the left of the body pane.

I have looked at http://jqueryui.com/demos/sortable/ and it almost does what i need, although it sorts from top to bottom and reversal. Is there anything possible to do 开发者_开发百科the same only from left to right and in reversal.


jQuery UI sortable should do just fine.

Let's say your divs have a class "foobar". Just give them a width and float them:

div.foobar {
  width:100px;
  float:left;
  margin-right:5px;
}
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜