BH

I created a slider of thumbnail images. I write the image filepaths
directly into the HTML using PHP, so instead of using expandos I
placed a hidden div after each image containing the file name of the
large version to be shown onclick. Works fine in FF and Chrome. IE
stops at the first line in the function, at .siblings(). It throws an
error saying 'Object does not support this property or method.'

$('.pic_listing img').click(function(){
                // Set the a variable with large image associated with
the thumb
                lg_pic = $(this).siblings('.lg_pic_name').html();

                // If it is not currently displayed
                if($('#lg_pic_src').attr('src') != path+lg_pic){
                        //Hide Old Image
                        $('#lg_pic_src').css('display','none');
                        //Replace it
                        $('#lg_pic_src').attr('src',path+lg_pic);
                        // Display Loader img
                        $('#loader').css('z-index',1);
                        // Once its loaded, Hide Loader and FadeIn the
new image
                            $('#lg_pic_src').load(function () {
                                        $('#loader').css('z-index',-1);
                                        $('#lg_pic_src').fadeIn();
                            });
                }
});

Anyone have any thoughts as to why IE would throw an error?
Other functions defined in the same file work fine.

Thanks,
Getzel

Reply via email to