I am trying to use the focus event on a list item. it works with freezing but not focused! Do you have an idea?
$('#main-menu ul.rubriques li')
.hover(function() {
$(this).addClass('active').find('ul').show();
})
.focus(function() {
$(this).addClass('active').find('ul').show();
});
I am trying to change my code: and find a solution;););)
$('#main-menu ul.rubriques li a')
.hover(function() { $(this).parent().addClass('active').find('ul').show();
})
.focus(function() { $(this).parent().addClass('active').find('ul').show();
});
thank! all!
source
share