开发者

jQuery UI draggable and sortable not working like I want it to

开发者 https://www.devze.com 2023-03-04 07:01 出处:网络
HI all. You can see the code right here: http://jsbin.com/egixa5/5/edit. I\'m trying to make it so when I drag an article, it only puts it between each article, not the elements inside each article. A

HI all. You can see the code right here: http://jsbin.com/egixa5/5/edit. I'm trying to make it so when I drag an article, it only puts it between each article, not the elements inside each article. Also, I'm not sure why it's duplicating the content, instead of just dragging and dropping it…

开发者_JAVA百科

Any ideas? I would really appreciate any help!


I'm trying to make it so when I drag an article, it only puts it between each article, not the elements inside each article.

Change $("#main").find('article').sortable(...) to $("#main").sortable(...).

Also, I'm not sure why it's duplicating the content, instead of just dragging and dropping it…

That would be the helper: clone bit.


I think you basically just want to model your code after this demo.

0

精彩评论

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

关注公众号