English 中文(简体)
Jquery - 甚至在发射吨前运行时运行。
原标题:Jquery - Run function even when function before hasn t fired.

这是在<条码>至(ggle)()功能中的一种氮。 我有一个头脑,在被点击时,下面的头盔击落,为被点击的头盔内容制造空间。

在那里做的是罚款,但我与头部在 st底有问题。 下面只有一位头盔,这样, following灭火中的内容的如下功能。

我想保持头盔的总体结构,使N失去功能。

$(currentHeader).next( li.header )
        .animate({ marginTop: itemHeight + 15 }, 1000, function ()
        {
            $(this).prev( ul#work-headers li ).find( ul ).fadeIn(500);
        });

任何帮助都会受到高度赞赏。

最佳回答

我要说,有两项解决办法:

快速和 d脏:

添加一个空洞的低收入国家:

<li class="header" style="display:none;"></li>

或者将法典修改为法典,在每度过一次电离层电离层后增加或增加部分电离层。

问题回答

我可以真心实意地检验这一点,这样,你就不得不与kin子做斗争,但基本想法是cap开你想要的逻辑,以便在某些情况下可以单独援引。

var fadeIn= function(content) {
                    $(content).find( ul ).fadeIn(500);
                }  
var next = $(currentHeader).next( li.header );

if(next.length>0) {
    next.animate({ marginTop: itemHeight + 15 }, 1000, function ()
        {
            fadeIn($(this).prev( ul#work-headers li ));
        });
}
else {
    fadeIn($(this).find( ul#work-headers li ));
}

edit - 就像@Holger 一样,更能诚实





相关问题
getGridParam is not a function

The HTML: <a href="javascript:void(0)" id="m1">Get Selected id s</a> The Function: jQuery("#m1").click( function() { var s; s = jQuery("#list4").getGridParam( selarrrow )...

selected text in iframe

How to get a selected text inside a iframe. I my page i m having a iframe which is editable true. So how can i get the selected text in that iframe.

jQuery cycle page with links

I am using the cycle plugin with pager functionality like this : $j( #homebox ) .cycle({ fx: fade , speed: fast , timeout: 9000, pager: #home-thumbs , ...

jquery ui dialog opens only once

I have a button that opens a dialog when clicked. The dialog displays a div that was hidden After I close the dialog by clicking the X icon, the dialog can t be opened again.

jConfirm with this existing code

I need help to use jConfirm with this existing code (php & Jquery & jAlert). function logout() { if (confirm("Do you really want to logout?")) window.location.href = "logout.php"; } ...

Wrap text after particular symbol with jQuery

What I m trying to do, is wrap text into div inside ll tag. It wouldn t be a problem, but I need to wrap text that appears particularly after "-" (minus) including "minus" itself. This is my html: &...

热门标签