English 中文(简体)
j Query Animation,chaining, .each() and .animate(or fadeIn() and fadeOut())
原标题:jQuery Animation, Chaining, .each() and .animate() (or fadeIn() and fadeOut())

我有一点麻烦,今天试图说明这一点,即想在我的人力部内制造5件物品(列在同一属性要素下),有的放矢,有的放矢,在阅读关于APICi思想的比喻之后,这将会成为实施缺陷和 show光灯的暗指。

然而,目前使用的是一米:

$( .elements ).each(function() {
    $(this).fadeIn(2000).delay(200).fadeOut(2000).show();
})

但是,所有事情一劳永逸。

在把所有事项合并在一起,从清单的第一个项目(a.k.a-(要素0))开始到最后一个项目,然后又重新开始的时候,如何发挥必然的影响?

在javascript/jquery这样做时是否确实需要这样做? 我希望,类似的功能,即可以链条,使 j能够减少负荷和档案。

此外,是否有办法限制我从散射中流出的图像?

最佳回答
问题回答

您的外溢情况,以国家安全局为主:

div.(class) { position:relative; overflow:hidden; }

美丽的道路:

(function hideNext(jq){
        jq.eq(0).hide("slow", function(){
            (jq=jq.slice(1)).length && hideNext(jq);
        });

})($( a ))

最近一次:

(function hideNext(jq){
                jq.eq(jq.length-1).hide("slow", function(){
                    (jq=jq.slice(0,length-1)).length && hideNext(jq);
                });

})($( a ))




相关问题
CSS working only in Firefox

I am trying to create a search text-field like on the Apple website. The HTML looks like this: <div class="frm-search"> <div> <input class="btn" type="image" src="http://www....

image changed but appears the same in browser

I m writing a php script to crop an image. The script overwrites the old image with the new one, but when I reload the page (which is supposed to pickup the new image) I still see the old one. ...

Firefox background image horizontal centering oddity

I am building some basic HTML code for a CMS. One of the page-related options in the CMS is "background image" and "stretch page width / height to background image width / height." so that with large ...

Separator line in ASP.NET

I d like to add a simple separator line in an aspx web form. Does anyone know how? It sounds easy enough, but still I can t manage to find how to do it.. 10x!

热门标签