The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums JavaScript JQuery Slidedown and Up

  • This topic is empty.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
  • #44414

    Hi guys,

    I’m working on a long menu, the options of which are hidden until the menu is hovered over, whereupon the options are revealed.

    The problem is when the menu is fully open, then hovered away from, then re-hovered over. It jerks either fully open or fully closed.

    This is because if the second stop parameter isn’t set to true then the menu can be “paused” in a half open/half closed state.

    Thanks in advance for any response,

    jQuery(‘#c_menu_wrap’).hover(function() {
    jQuery(this).children(‘#c_menu_int’).stop(true, true).slideDown();
    }, function() {
    jQuery(this).children(‘#c_menu_int’).stop(true, true).slideUp();

    (We can’t use the css transition here as the height needs to be auto due to us not being in control of how many options are in the menu.)


    Oh, and without any “stop” functions, it queues up animations indefinitely!

    I’m basically hoping for a way that, if it is beginning the slideup anim, then hovered over, then it will start sliding down without either first jumping or completing the slideup animation.


    Did you try changing the stop function parameters `.stop( [clearQueue ] [, jumpToEnd ] )` ([ref](

    Maybe try `.stop(true, false)` and see if that does what you want.

Viewing 3 posts - 1 through 3 (of 3 total)
  • The forum ‘JavaScript’ is closed to new topics and replies.