English 中文(简体)
湿度
原标题:jquery if mouseover

我有传承功能,可以揭示一个因素。 这一新内容中有一些重叠之处,如果我接着把眼光放在新内容上,因为 cur子已经不再是表面,而这个要素本身就隐藏起来,然后立即重新出现,因为 cur子再次倒。 如果 cur子超越了新内容(这是主要形象重叠的新要素的唯一部分),我需要 some然无视 mo子的指挥。

它是解释的trick笑,但这里是法典:

jquery (有一点点不确定如何做)

$("div > img").hover( function() {

        $(this).parent().find("span").slideDown(100);

    }, function() {

        if (user is hovering over the span) {
                    // do nothing
        } else {
            $(this).parent().find("span").slideUp(100);
        }
    });

html

<div>
    <img src="/images/icons/dm.jpg" width="54" height="54" />
    <span><strong>Test</strong><br />test2<img src="/images/arrow.png" width="19" height="17" /></span>
</div>
最佳回答

http://api.jquery.com/hover/rel=“nofollow”>:.hover( on that parent <div> so:

$("div").hover(function() {
    $(this).find("span").slideDown(100);
}, function() {
    $(this).find("span").slideUp(100);
});

由于你实际上只想影响<代码>和>;span>,在接任<代码>和t;div>(其中只有<代码>和t;img>最初可见)。 我只想到:<div>,你可以选中(使其更加具体)使用某些类别,并重新确定。

问题回答




相关问题
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.

How to fire event handlers on the link using javascript

I would like to click a link in my page using javascript. I would like to Fire event handlers on the link without navigating. How can this be done? This has to work both in firefox and Internet ...

How to Add script codes before the </body> tag ASP.NET

Heres the problem, In Masterpage, the google analytics code were pasted before the end of body tag. In ASPX page, I need to generate a script (google addItem tracker) using codebehind ClientScript ...

Clipboard access using Javascript - sans Flash?

Is there a reliable way to access the client machine s clipboard using Javascript? I continue to run into permissions issues when attempting to do this. How does Google Docs do this? Do they use ...

javascript debugging question

I have a large javascript which I didn t write but I need to use it and I m slowely going trough it trying to figure out what does it do and how, I m using alert to print out what it does but now I ...

Parsing date like twitter

I ve made a little forum and I want parse the date on newest posts like twitter, you know "posted 40 minutes ago ","posted 1 hour ago"... What s the best way ? Thanx.

热门标签