I want to have an object which is both resizable and draggable. I'll need:
- X
- Y
- Size
of the object.
Is this possible?
There is an example on http://www.jsfiddle.net/davidThomas/DGbT3/1/ which gets the x and y of the draggable object. How can I also make it resizable?
Thanks
It's worth adding that this question is related to, and built on, this previous question: How to get the position of a draggable object?
Sure it is... jQuery UI is good for complex behaviors like drag and drop, resizing, selection and sorting.
With jQuery UI you can:
And you can everything chain together.
It is important for the resize feature that you include the
jquery-ui.css
file.JSFIDDLE: http://jsfiddle.net/uQWRk/
Here is the full code for archive:
See comments: