3

My Fancybox slideshow only works once and stops. From what I can tell is that it's not looping back because something broke which I can't figure out what. If you go to their page to "Extended functionality" and try it out you'll see that it's not working there either.. or at least for me.

<!-- Add Fancybox library -->
<script type="text/javascript" src="http://www.Website.com/+Fancybox/lib/jquery.mousewheel-3.0.6.pack.js"></script>
<script type="text/javascript" src="/+Fancybox/jquery.fancybox.js"></script>
<link rel="stylesheet" type="text/css" href="http://www.Website.com/+Fancybox/jquery.fancybox.css" media="screen" />
<link rel="stylesheet" type="text/css" href="http://www.Website.com/+Fancybox/helpers/jquery.fancybox-buttons.css" />
<script type="text/javascript" src="http://www.Website.com/+Fancybox/helpers/jquery.fancybox-buttons.js"></script>
<link rel="stylesheet" type="text/css" href="http://www.Website.com/+Fancybox/helpers/jquery.fancybox-thumbs.css" />
<script type="text/javascript" src="http://www.Website.com/+Fancybox/helpers/jquery.fancybox-thumbs.js"></script>
<script type="text/javascript" src="http://www.Website.com/+Fancybox/helpers/jquery.fancybox-media.js"></script>

<!-- Fancybox Properties -->
<script>
$(document).ready(function() {

    $.noConflict();

        $('.fancybox').fancybox({
        padding     :  0,
        prevEffect  : 'fade',
        nextEffect  : 'fade',
        openEffect  : 'elastic',
        closeEffect : 'elastic',
        autoPlay    : 'true',
        mouseWheel  : 'true',
        helpers     : {
            buttons : {},
            title   : {
                    type: 'outside'
            }
        }
    });
});
</script>

Responsive Fancybox: http://www.fancyapps.com/fancybox/

Google Chrome: v24.0.1312.57

JFK
  • 40,963
  • 31
  • 133
  • 306
Z33
  • 61
  • 2
  • 7
  • I'm sorry I don't get what you mean. If I try the examples the seem to work perfectly fine. Can you explain in more detail what the problem is? – Florian Rachor Feb 21 '13 at 16:54
  • If you go down to "Extended functionality" and open up a image. There's a bar that shows up at the top with various buttons. If you try to start the slideshow with the play button it will go one image forward and stop. – Z33 Feb 21 '13 at 17:00
  • O.K thnx for the clarification. I can confirm this problem, but this looks like a bug in fancybox to me, so maybe file / search in the github issues: https://github.com/fancyapps/fancyBox/issues – Florian Rachor Feb 21 '13 at 17:05
  • If there's a bug in the plugin, you're posting in the wrong place. SO is for help fixing _your_ code, not a bug reporting or discussion site. Contact the developer and/or post this on Github. Thanks. – Sparky Feb 21 '13 at 17:07
  • Yeah their page told me to come here or Github so I'll give a shot at Github and see how that goes. If any one figures it out please give me a heads up. Thanks guys – Z33 Feb 21 '13 at 17:08

2 Answers2

4

I can confirm that there is a bug if using jQuery 1.9.x

Fancybox v2.1.3 was broken using jQuery 1.9.x as you can see it here. Then v2.1.4 was released to make it work with jQuery v1.9.x but it seems to me that the buttons helpers js file has to be patched as well.

As a workaround, you can rollback to jQuery v1.8.3.

See a working JSFIDDLE using jQuery 1.8.3.

See a broken JSFIDDLE using jQuery 1.9.1.

PS. I did open an issue at github

** UPDATE :

The issue was fixed in the last commit (not updated in fancyapps home page samples neither the downloadable file though)

Community
  • 1
  • 1
JFK
  • 40,963
  • 31
  • 133
  • 306
0

I don't know if this causes your problem, but if you set jQuery.noConflict(); you have to use jQuery instead of $ like this: jQuery('.fancybox').fancybox({...

Florian Rachor
  • 1,574
  • 14
  • 31