jquery hover and setTimeout / clearTimeOut

后端 未结 4 1928
北海茫月
北海茫月 2020-12-29 16:56

I\'m currently trying to do a menu with submenu. Here is what i want to do.

On hover a link (#mylink) i want to display a div (lets call it \"#submenu\") right under

4条回答
  •  北海茫月
    2020-12-29 17:36

    var timer is a local variable.
    It doesn't exist outside that handler.

    You need to make it a global variable.

提交回复
热议问题