Two pits encountered with jQueryUI draggable and droppable

Source: Internet
Author: User

jQueryUI's drag-and-drop plugin greatly facilitates the developer's implementation of the drag-and-drop function, but the official tutorial is too general, in the concrete implementation of a lot of places are not clear, here say I met two "small pits":

The Clone property of the 1:draggable.

2:droppable accept the positioning of the drag control (where to put it)

First is the first "pit", in doing something similar to the editor, we need to implement a similar drag control function, that is, from the toolbar to the "formula bar". This requires the Clone property, and the formula bar does not display the clone control when you use this property to achieve the effect. The verification needs to be accepted (added) in the acceptance column, which is the edit bar.

The code doesn't have a screenshot.

Next is the second "pit": the positioning of the dragged control is actually very simple to do an absolute positioning and set the distance from the left of the upper margin is OK, I am not familiar with the plug-in Leng out of the pit (⊙﹏⊙) ~ ~ ~

Graphic:

Thought through the very good understanding, the code here is very simple, is to specify the use of drag-and-drop plug-in process of two blind spots ~ I hope that the development of the novice (including me ~ ~ ~) Some help!

Two pits encountered with jQueryUI draggable and droppable

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.