0

我正在使用花哨的框 2,但是当我单击链接打开幻灯片时,所有图像都会立即显示。有时它会添加一个滚动条....见下面的代码

http://jsfiddle.net/Tx3AF/

抱歉,我无法添加fancyboox JS 来显示画廊。任何帮助将不胜感激...我在互联网上搜索过,但没有运气...

谢谢。

4

1 回答 1

1

if you are using this

$(".fancybox").fancybox({
    openEffect: 'none',
    closeEffect: 'none'
});​

then just add the class fancybox to all <a> tags that target an image of the same gallery.

Your first link

<a class="fancybox" href="#morephotos">This shows ...

should actually target the first image of the gallery

<a class="fancybox" href="firstImage.jpg" rel="gallery">This shows....

... otherwise will show whatever is inside the <div> with id="morephotos".

Don't forget to wrap your custom fancybox script within the .ready() method like

  $(document).ready(function(){
    $(".fancybox").fancybox({
        openEffect: 'none',
        closeEffect: 'none'
    });​ // fancybox
  }); // ready
于 2012-07-26T07:28:47.117 回答