may88seiji
7/23/2017 - 2:47 AM

onHover

onHover

$('a img').hover(function() {
  $(this).attr('src', $(this).attr('src').replace('_off', '_on'));
}, function() {
  if ( !$(this).hasClass('current') ) {
    $(this).attr('src', $(this).attr('src').replace('_on', '_off'));
  }
});
//<a href="#"><img src="btn_01_off.png" alt="ボタン" /></a>