0

I am using fancybox and want to disable loading animation.

My code:

$(document).ready(function() {

    $("#mypop").fancybox({
     'onStart ': function(){ $.fancybox.hideActivity },
'onComplete' : function(){ $.fancybox.hideActivity }, 
    'href'                  : 'file.php',
    'transitionIn'      : 'none',
    'transitionOut'     : 'none',
    'titleShow' : false,
    'overlayColor'  :   '#fff',
    'overlayOpacity':   0.8,
        }); 
    });

And the loading animation still works what do I do worng ?

andys
  • 708
  • 3
  • 11
  • 29
  • try `$.fancybox.hideActivity();` ... also check that there is not spaces in the `onStart` callback, otherwise won't work – JFK Nov 16 '12 at 03:57

1 Answers1

1

The docs say $.fancybox.hideLoading() for v2 if that is any good to you. http://fancyapps.com/fancybox/#docs

Edit - @user1139767

You are missing the ()'s from the end of the $.fancybox.hideActivity() calls.

This post (http://stackoverflow.com/a/3673152/1791606) mentions the loading animation not appearing because of using an iframe as the type which accidentally achieves what you seem to be wanting to do.

qooplmao
  • 17,622
  • 2
  • 44
  • 69
  • Thank you for reply yeah I was trying many methods but with no luck... I guess will need to delete image. – andys Nov 16 '12 at 18:54