Nivo slider javascript problem in IE8- object doesn’t support this property or method

My Nivoslider works well in firefox, opera, safari, chrome, but not in IE8.
Somehow it shows an error: object doesn’t support this property or method

Apparently the error comes from this part of code:

if($  (kids[vars.currentSlide]).is('img')){vars.currentImage=$  (kids[vars.currentSlide]);}
else{vars.currentImage=$  (kids[vars.currentSlide]).find('img:first');}

the error is on the second line code, which is:

else{vars.currentImage=$  (kids[vars.currentSlide]).find('img:first');}

What’s wrong with that code the causes an error in IE8?

Thanks before!

newest questions tagged jquery – Stack Overflow

About Admin