Ahhh ok this makes more sense.   Now will this also solve the problem
of the fact that it's storing the old carousel data?  For example, I
have a slideshow running, looping through each picture.

I'm using this code:

                        itemVisibleInCallback: {
                                onBeforeAnimation:
mycarousel_itemVisibleInCallbackBeforeAnimation
                        },
                        itemVisibleOutCallback: {
                                onAfterAnimation:  
mycarousel_itemVisibleOutCallbackAfterAnimation
                        },

and then an example of one of the functions is this:


function mycarousel_itemVisibleInCallbackBeforeAnimation(carousel,
item, idx, state) {
        $('#my-carousel-nav li#my-carousel-' + idx).addClass("current-
image");
};

function mycarousel_itemVisibleOutCallbackAfterAnimation(carousel,
item, idx, state) {
        $('#my-carousel-nav li#my-carousel-' + idx).removeClass("current-
image");
};

The problem I'm running into is that if the slideshow is on say
picture 3, and I click a link to ajax load in a new caroursel, what
happens is on the new carousel, it shows item 1 highlighted, but it
also shows item 3 highlighted from the last slideshow.  If I go to
load it again, then there's 3 instances of the 'current' item being
highlighted.... meaning   1, 3 and 7 etc also have that class added.

How do I 'reset' the data I guess is my question.

Thanks again for the reply!

-Matt

On Nov 28, 8:26 am, Denes PAL <[EMAIL PROTECTED]> wrote:
> Hi,
>
> when the page is loaded in the background (iframe, ajax) while using a
> loader animation, the ready event triggered before the items has been
> shown. So the jCarousel can not get the correct dimensions. The
> solution is to init jcarousel after the content has been shown, by
> explicitly call the init function, or specify a new onload type event
> and catch it correctly.
>
> ds
>
> matt wrote:
> > I have a site that uses jcarousel.  This works fine, but I also have
> > links on the side, that when clicked, loads in new content via ajax
> > (new page content and new carousel).  The problem is that jcarousel
> > stopped working, using this message:
>
> > jCarousel: No width/height set for items. This will cause an infinite
> > loop. Aborting..
>
> > Ok, so no problem, I'll just use livequery to fix the problem.  Well
> > it added the images to the carousel, and started to cycle through, but
> > I still got this message:
>
> > jCarousel: No width/height set for items. This will cause an infinite
> > loop. Aborting..
>
> > Even when I'm loading in pages via ajax that do not have the ID that
> > utilizes the jcarousel, I get the error message.  Anyone have any idea
> > how to fix this?

Reply via email to