Closed cmcnaught closed 10 years ago
Reproducible test case, please.
Great product, I love it and the way it's put together. Here's a test case: http://www.cciwebs.com/development/carouseltest/ I based this on the basic carousel example in the download then added a button to replace the list with only images 4,5,6. After reload the images update to only 3, scroll works but the pagination breaks. Thanks, Colin
I can't open that page (times out).
Must have been a temporary problem, works for me on Chrome36/IE11/Safari6/Firefox30 http://www.cciwebs.com/development/carouseltest/ Let me know, Colin
On Tue, Aug 19, 2014 at 8:42 AM, Jan Sorgalla notifications@github.com wrote:
I can't open that page (times out).
— Reply to this email directly or view it on GitHub https://github.com/jsor/jcarousel/issues/708#issuecomment-52627150.
Use this:
$("ul#testlist").html(newlist);
$('.jcarousel').jcarousel('reload');
$('.jcarousel-pagination').jcarouselPagination('reloadCarouselItems');
Hi Jan, Sequence didn't work for me, required two clicks, However adding 'reloadCarouselItems' before the 'reload' worked fine. (See below and in test case): http://www.cciwebs.com/development/carouseltest/ Problem solved. Thanks, Colin
On Wed, Aug 20, 2014 at 12:38 AM, Jan Sorgalla notifications@github.com wrote:
Use this:
$("ul#testlist").html(newlist);$('.jcarousel').jcarousel('reload');$('.jcarousel-pagination').jcarouselPagination('reloadCarouselItems');
$("ul#testlist").html(newlist); $('.jcarousel-pagination').jcarouselPagination('reloadCarouselItems'); $('.jcarousel').jcarousel('reload');
— Reply to this email directly or view it on GitHub https://github.com/jsor/jcarousel/issues/708#issuecomment-52733262.
Yes, sorry, my bad.
Hi Jan, Thanks for Jcarousel ! When you press the button pagination I upload new ellementy carousel and then reload carousel. This becomes the first active ellement. How can I make the active ellement which I pressed? I do so: .... if (products.length > 0){ var number = $(item).find('.active').text(); $(item).jcarouselPagination('reloadCarouselItems'); $('.jcarousel').jcarousel('reload'); $(item).find('.active').removeClass('active'); $(item).find('a:contains("' + number + '")').addClass('active');
}
.... $(item) - it is the '.jcarousel-pagination' The desired ellement becomes active, but when I click on the following ellement pagination, currently active remains active ellement.
Having modified the item list via Ajax/javascript, the pagination still retains the old number of items and doesn't update when list is scrolled after calling reload(). Is there a way to 'reload' the pagination?