私が取り組んでいるページには、それぞれが 1 つの画像を含む個別の div-id を含む div-id (dragZone) があり、これらはすべてドラッグ可能で、サイズ変更可能で、クリックすると前方に表示されます。
.resizable を機能させるために、 $('img').resizable を入力しましたが、これはもちろん、ページ上の他のすべての画像に影響を与えています。
dragzone-id にある画像ファイルにのみ影響を与えるように .resizable を作成する方法はありますか?
$(document).ready(function() {
var a = 3;
$('#dragZone > div').draggable({
start: function(event, ui)
{ $(this).css("z-index", a++); }})
$('img').resizable({maxHeight: 600, aspectRatio: true, animate: true });
$('#dragZone > div').click(function() {
$(this).addClass('top').removeClass('bottom');
$(this).siblings().removeClass('top').addClass('bottom');
$(this).css("z-index", a++);
});
});