Solved

jCarousel Pagination

Posted on 2011-09-06
3
1,322 Views
Last Modified: 2012-06-27
Hi,

does anyone know how to get the total number of items in jCarousel

I am trying to create a 1 of 7 , 2 of 7 pagination so the users know what slide they are on.



Thanks
0
Comment
Question by:coolispaul
  • 2
3 Comments
 
LVL 82

Accepted Solution

by:
leakim971 earned 500 total points
ID: 36490948

var total_number = $(".jcarousel-item").length;

Open in new window

0
 

Author Comment

by:coolispaul
ID: 36491174
great that works but do you know how to make a pagination function for jcarousel potentially using this.

I tried the following without much luck:

jQuery('#mycarousel2').jcarousel({
      wrap: 'circular',
      scroll:1,
      itemLoadCallback: trigger
    });

   
    function trigger(carousel, state) {
       
      var total_number = $("#mycarousel2 .jcarousel-item").length;

      if(carousel.first > total_number) { $("#counter").html(1); } else { $("#counter").html(carousel.first);}
 
    }
0
 
LVL 82

Expert Comment

by:leakim971
ID: 36491186
No, I don't know, sorry.
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

Suggested Solutions

International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
In this tutorial viewers will learn how to style elements, such a divs, with a "drop shadow" effect using the CSS box-shadow property Start with a normal styled element, such as a div.: In the element's style, type the box shadow property: "box-shad…
In this tutorial viewers will learn how to embed Flash content in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: "<!DOCTYPE html>": Use the <object> tag to embed Flash content.: To specify that the object is Flash content, d…

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now