1
我正在使用尾部滑块制作网站,我希望根据div中的图像宽度设置panelWidth。我可以使面板宽度是尾部滑块内图像的宽度吗?
$(".panel").each(function(){
var imageWidth = $(this).find("img").width()+1;
$(this).width(imageWidth);
});
任何想法?
您的代码有效。 http://jsfiddle.net/ynhat/Fqupf/ – YNhat 2011-03-15 08:45:49
@YNhat代码可以工作,但不能与尾部滑块jQuery-Plugin结合使用。这对舞台的剪辑区域使用宽度... – michelgotta 2011-03-15 09:09:02
我觉得我快到了,只需要对舞台的“剪辑区域”进行排序。可以这么说.. – 2011-03-16 10:48:13