jQuery - Using .one() with hover

Posted by Jared on Stack Overflow See other posts from Stack Overflow or by Jared
Published on 2011-01-09T10:29:03Z Indexed on 2011/01/09 10:53 UTC
Read the original article Hit count: 150

Filed under:

Is there any way to get a hover function to only execute once? This is what I'm currently trying:

$('#ask').live('hover', function() {

    $('#homesearch-after').hide(300);

    $.doTimeout( 300, function() {
        hideClosedSearchLink();
        showHomeSearch();
    });

});

But that's not working. How can I only get this hover to activate once?

I've tried changing .live with .one and .bind... resulting in nothingness.

© Stack Overflow or respective owner

Related posts about jQuery