diff --git a/jquery.nivo.slider.js b/jquery.nivo.slider.js index fa82ebb..0bd80c9 100644 --- a/jquery.nivo.slider.js +++ b/jquery.nivo.slider.js @@ -353,13 +353,22 @@ // Set current background before change if (!nudge) { - sliderImg.attr('src', src(vars.currentImage)); + sliderImg.prop({ + src: src(vars.currentImage), + alt: vars.currentImage.attr('alt') + }); } else { if (nudge === 'prev') { - sliderImg.attr('src', src(vars.currentImage)); + sliderImg.prop({ + src: src(vars.currentImage), + alt: vars.currentImage.attr('alt') + }); } if (nudge === 'next') { - sliderImg.attr('src', src(vars.currentImage)); + sliderImg.prop({ + src: src(vars.currentImage), + alt: vars.currentImage.attr('alt') + }); } }