Skip to content Skip to sidebar Skip to footer

Slide Input On Hover And Stay For Few Seconds

How to open the input box on hover an icon and it should stay open for few seconds then it should automatically slide back to the initial position. I have tried in css but I need t

Solution 1:

You may take a look on CSS Animations.


Solution 2:

Try this:

<script>
    $('.media').mouseenter(function(){
        $('img').hide();
        $('.media').width('25%');
    });
    $('.media').mouseleave(function(){
        setTimeout(function(){
            $('.media').width('6%');
            setTimeout(function(){$('img').show()},1000);
        },3000);
    });
</script>

Fiddle http://jsfiddle.net/aVDgk/2/


Post a Comment for "Slide Input On Hover And Stay For Few Seconds"