开发者

jquery grab and move toggle element

i have a div that is displayed via:

$('a#biz-blue-lnk').click(function() {
    $('#business-blue').show();
    return false;
  });

what i want to figure out is when this DIV is displayed, can i enable the user to grab it and move it around the scre开发者_如何学JAVAen? potentially if they click another DIV they could have two elements on screen... and would like them to be able to move them around to see each one...

possible?


Look into jQueryUI & the draggable() functionality.


Check out the Draggable, part of jQuery UI. It's as simple as $('#business-blue').draggable(); then!

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜