0

我的网站上有一些 jQuery 问题,但我不知道我的问题是什么。有人可以检查一下吗?由于某种原因,Firefox 的问题最多。

动画是简单的 jquery 动画,应该很好用,但在我的浏览器上一点也不流畅。 http://myfirstletters.com/base.html http://myfirstletters.com/media/js/functions.js(动画在函数 start_animation 和 move_js 中) http://myfirstletters.com/media/js/main。 js

感谢您的时间

function start_animation() {
   $('#website').stop().animate();
   window_height= $(".intro").height();
   animation = ((window_height)*-4)-20;
  $('#intro_website').css('marginTop', -window_height-20);

  $('#intro_website').animate({
     marginTop: animation
   }, 17000,  'linear', function(){
     status=true;
     $('#intro_website').stop().animate();
     $('#website').css('zIndex', 1);
     $('#intro_website').css('display', 'none');
     $("#skip").css('display', 'none');
   });
}
4

1 回答 1

0

完成后(或跳过它时)删除介绍动画。该网站的动画会更流畅一些。

$('#intro_website').remove();

您应该对不在视口中的所有元素执行此操作。当它们需要显示时,您可以使用 ajax 加载它们。

希望它有点帮助!

于 2011-12-13T12:19:01.757 回答