我想使用fancybox在彈出窗口中顯示原始圖像,但它似乎沒有工作。而是調整圖像和容器的寬度和高度。使用fancybox顯示原始圖像
這是我在做什麼:
$("a.fancybox").fancybox({
padding : 0,
height : $(this).attr('data-height'),
width : $(this).attr('data-height'),
autoDimensions: false
});
我的鏈接:
<a href="/system/creatives/images/000/000/008/original/new_creative_form.png?1402035793" data-width="1366" data-height="768" class="fancybox">
<img src="/system/creatives/images/000/000/008/thumb/new_creative_form.png?1402035793" class="img-responsive" alt="New creative form">
</a>
任何想法,我應該怎麼辦呢?
你有沒有試過不提供'width'和'height'參數? –
@RoryMcCrossan呀還是它調整圖像大小。 –