We help IT Professionals succeed at work.

Pause Jquery Cycle when Fancybox opened

flashjordan
flashjordan asked
on
1,576 Views
Last Modified: 2012-05-10
Hi,

I have a little issue with my site that I cannot solve. you can see the issue at conceptparadise.com/dm The problem is that when I open a flash animation in fancybox over the top of jquery cycle, the flash animation stahhers when the banners in the background rotate.

What I am trying to do and failing at it pausing the cycle plugin when the fancybox is opened and then resuming the cycle plugin once fancybox is closed.

I have attached the two example of code that I have at the moment and where i have got to. What I am going is probably wrong!!!

I would really appreciate any help that anyone could give me as I am going crazy with this..

Thank you in advance
<!-- Banner Rotator -->    
 <script type="text/javascript" src="http://cloud.github.com/downloads/malsup/cycle/jquery.cycle.all.2.74.js"></script>
<script type="text/javascript">
$(function() {
    $('#s3').cycle({fx: 'fade',speed: 1500 });
});
/*
$('#pauseButton').click(function() { 
    $('#s3').cycle('pause'); 
});
$('#resumeButton').click(function() { 
    $('#s3').cycle('resume', true); 
});
*/
$('#fancybox-wrap').show('slow', function() {
	alert('fancybox show');
    $('#s3').cycle('pause'); 
});
$('#fancybox-wrap').hide('slow', function() { 
    $('#s3').cycle('resume', true); 
});
</script>


<!-- Example of Fancybox call -->

$("#Dentiframe4buttons1").fancybox({
				'width':700, 
				'height':405,		
				'type':'iframe', 
				'autoScale':'false' 
			});

Open in new window

Comment
Watch Question

Top Expert 2009
Commented:
Unlock this solution and get a sample of our free trial.
(No credit card required)
UNLOCK SOLUTION

Author

Commented:
That is amazing, if I could give you more points I would as you have solved somethi9ng that has been causing me nightmares... Thank you so much!!!
Top Expert 2009

Commented:
Thank you :)
Unlock the solution to this question.
Thanks for using Experts Exchange.

Please provide your email to receive a sample view!

*This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

OR

Please enter a first name

Please enter a last name

8+ characters (letters, numbers, and a symbol)

By clicking, you agree to the Terms of Use and Privacy Policy.