6.Hover


#1


Hi guys sorry Dumb me facing problem again :stuck_out_tongue:

This is my code. It shows me "Oops, try again. It does't look like your background color changed, is your hover adding the class active?".


$(document).ready(function(){

  $('div').hover(
    function(){
    $(this).addClass('active');
    },
    function(){
    $(this).removeClass('active');    
    }
  );

});


#2

move your mouse into div and wait 1/2 second then move your mouse out of div.


#3

Oh it worked! Thx mate!


#4

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.