Advertisement
Guest User

Untitled

a guest
Jun 18th, 2019
99
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.37 KB | None | 0 0
  1. $('#menu').on('mouseover', '> li', function(e) {
  2. # attach hover event to the menu, and check which LI you are hovering
  3. if (!$(this).hasClass('.current)')) {
  4. $('.current', '#menu').removeClass('active');
  5. }
  6. }).on('mouseout', '> li', function (e) {
  7. if (!$(this).hasClass('.current)')) {
  8. $('.current', '#menu').addClass('active');
  9. }
  10. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement