开发者

PageLoad in Animate Callback with JQuery

I would like to do page load event when animation is ende开发者_运维百科d. That's may be pretty simple. Here is my Jquery code

$('#reload span').click(function () {
   $('#dl-area').animate('blink', 'fast', null, function () {
       location.reload();
   });
});

It's not working.


If you want the jQuery UI pulsate effect (based on comment above), make sure you're using jQuery UI (or just the subset you want) and use .effect() instead of .animate() (which doesn't take a string as it's first argument), like this:

$('#reload span').click(function() {
   $('#dl-area').effect('pulsate', 'fast', function() {
       location.reload(true);
   });
});
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜