Is it possible to use JQUERY-UI draggable with elements that are imported asynchronously using jquery's .load function? I guess that I would need to use .on or .bind, but can't figure out something that works...
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
I would just use the .load callback to assign the draggable property:
$("#containerselector").load('path', function () {
$(this).find( "elementsthatshouldbedraggableselector" ).draggable();
});