jQuery.addClass not working
Use it without dot:
$(function(){
$('#menuNav').hover(function(){
$('#huh').addClass('opacity');
}, function(){
$('#huh').removeClass('opacity');
});
});
$( function() {
$('#menuNav').hover( function() {
$('#huh').toggleClass('opacity');
});
});
.hover()
makes many events, better to use .mouseenter()
. Note also that when adding class you don't have the .
(dot).
$(function(){
$('#menuNav').mouseenter(function(){
$('#huh').addClass('opacity');
}, function(){
$('#huh').removeClass('opacity');
});
});