Giter Club home page Giter Club logo

jcarousel's Introduction

jCarousel - Riding carousels with jQuery

jCarousel is a jQuery plugin for controlling a list of items in horizontal or vertical order. It provides a full-featured and flexible toolset for navigating any HTML based content in a carousel-like fashion.

Note: Version 0.3.x and 0.2.x are not compatible. Old versions can be downloaded from the release page.

Documentation

The documentation can be found here.

Reference

Plugins

By default, the jCarousel core only contains the minimum functionality needed to create carousel widgets. Specialized features are provided through plugins.

jCarousel comes with the following plugins:

Third-Party Plugins

Download

All ready-to-use files are located in the dist/ directory.

The jquery.jcarousel.js and jquery.jcarousel.min.js files contain the core and all plugins concenated together.

All files are also available from CDNJS.

Examples

You can find some example implementations in the examples/ directory. You can also browse the functional tests to get an impression of how to setup jCarousel.

Credits

jCarousel is written on top of jQuery and was originally inspired by the Carousel Component by Bill Scott.

License

Copyright (c) 2006-2020 Jan Sorgalla. Released under the MIT license.

jcarousel's People

Contributors

davetrollope avatar davidmcooper avatar iammerrick avatar jsor avatar kkirsche avatar lespacedunmatin avatar snake-345 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

jcarousel's Issues

Image with Text

Hello,

I am really thankful for your great algorithm.

I have been trying to this one thing but it all goes into vain. I will really be thankful if you can help me with this.

What I am trying to do is that I want to have Heading and a small description with every image and I have been pleading the script to do that but it never listens to me :(.

Something like this.

                   |
                   |
                   |

Heading
Description

Would be really thankful to you if you can help.

Many Thanks.

Slow response time with many images

I am trying to use the jCarousel plugin with 150 images, but the response times are very slow (especially when using the "circular" mode and wrapping from front to back). The response times are especially slow in IE. It seems the calculations could be made to run faster?

Last Item cut

Hey m8,
first of all thx for the carousel.
But I still have small issues with it :-S
The amount images being scrolled does not fit with the amount I define in the ready-function

jQuery(document).ready(function() {
    jQuery('#mycarousel').jcarousel({
        size: mycarousel_itemList.length,
    scroll: 30,
..

and, sometimes the last Item is just cut or lies under the arrow (if I change the css) - which is obviously a problem caused by the margin or border of the <li>-items. As the border of the <li> will be streched I set this to none and chose to give a border 1px solid to the img inside.

I played around a bit with the css, but I can't solve the probs I guess...maybe you could have a quick look at http://jagas.de/rm/weiss/portfolio.html (which is under progress)?

multiple carrousels in multiple tabs

I am not sure about this beeing a bug, but I have been fighthing with that for the last couple of hours.

I am having multiple jcarousel on one page. (so far, so good)
Every carousel is within a specific tab and only one of those tabs is actually visible at start.

Chrome is throwing errors of not "defined width for items" and exits the script.
(FF3.6 says nothing and works fine)
I suppose having display:none in a wrapper tab is inherited and thus not width given to items.

I need to say I have tried to hide my tabs on callback after init etc... many things... but, could get it to work not only with css

I managed to find a way around by postion:asbolute and a higher z-index to the first to load tab.
Then the show / hide on menu click works.

anybody experienced such issue ?

Multiple bind on prev/next buttons

I've recently found, that function buttons is called on every animate event. Thus next and prev events are binded so many times, as many times user clicked at navigation buttons.
I suggest to unbind all handlers of prev/next buttons:
/**
* Sets the states of the prev/next buttons.
*
* @method buttons
* @return undefined
*/
buttons: function(n, p) {
if (n == undefined || n == null) {
var n = !this.locked && this.options.size !== 0 && ((this.options.wrap && this.options.wrap != 'first') || this.options.size == null || this.last < this.options.size);
if (!this.locked && (!this.options.wrap || this.options.wrap == 'first') && this.options.size != null && this.last >= this.options.size)
n = this.tail != null && !this.inTail;
}

        if (p == undefined || p == null) {
            var p = !this.locked && this.options.size !== 0 && ((this.options.wrap && this.options.wrap != 'last') || this.first > 1);
            if (!this.locked && (!this.options.wrap || this.options.wrap == 'last') && this.options.size != null && this.first == 1)
                p = this.tail != null && this.inTail;
        }

        var self = this;

/* Start modification /
this.buttonNext.unbind(this.options.buttonNextEvent + '.jcarousel', this.funcNext);
this.buttonPrev.unbind(this.options.buttonPrevEvent + '.jcarousel', this.funcPrev);
/
End modification */
this.buttonNext[n ? 'bind' : 'unbind'](this.options.buttonNextEvent + '.jcarousel', this.funcNext)n ? 'removeClass' : 'addClass'.attr('disabled', n ? false : true);
this.buttonPrev[p ? 'bind' : 'unbind'](this.options.buttonPrevEvent + '.jcarousel', this.funcPrev)p ? 'removeClass' : 'addClass'.attr('disabled', p ? false : true);
},

Error with wrap on small carousels

Yesterday I had to create a small Carousel. "Small" in such way, that 5 Items are visble on startup and only one more hidden. I needed the carousel to wrap with 'last'. The problem was, that after the first next() the wrapping does not work. finally I found the solution in function pos():

var back = this.first >= i;

Before ist was

var back = this.first > i;

Carousel list width is incorrectly calculated

I'm using the most basic jCarousel call possible (the same as is displayed here), but the width of the ul element hosting the carousel is being incorrectly calculated.

My list items inside the carousel look like this:

<li style="cursor: default;" id="item1">
  <a style="cursor: default;" href="#" onclick="callFunction();" tabindex="1">
    <span style="cursor: default;">
      <img style="cursor: default;" src="../img/icon_16x16.png" alt="">
      Item Text
    </span>
  </a>
</li>

There are four items like this in the list. The ul's width is being calculated as 40px. The list items are sized at 75px through CSS, and appear to be rendered correctly (I have verified this with Firebug). Oddly, the jCarousel instance reports (in Firebug) .first = 1 and .last = 3, indicating that it might have missed the final item.

I'm using jCarousel 0.2.4 and jQuery 1.4.2. The problem is seen in Firefox 3.6, Chrome 5 and IE 8 (other browsers not tested).

Unfortunately, as the application is an internal component, an in-place demonstration cannot be provided.

buttonNextCallback is not called if buttonNextHTML is null

Title says it all. The question is: ¿Is it the right behaviour?

I am configuring jcarousel like this:

$('#carousel').jcarousel({
    visible: 1,
    scroll: 1,
    initCallback: carouselInitCallback,
    buttonNextCallback: carouselNextCallback,
    buttonPrevCallback: carouselPrevCallback,
    buttonNextHTML: null,
    buttonPrevHTML: null
});

If I remove last two lines (buttonNextHTML and buttonPrevHTML) callbacks are called.

I'd like buttonNextCallback and buttonPrevCallback to be called with my custom buttons. Is that possible?

Issue with {visible} argument

In "static_simple.html", if the jcarousel is called with {visible:1}, then the carousel no longer works properly - specifically, it skips over items.

jQuery(document).ready(function() {
    jQuery('#mycarousel').jcarousel({visible:1});
});

This remains consistent across other usages.

jcarousel on Chrome

Hi,

I try to use jcarousel but it is not 100% accurate on chrome. Sometimes it works just fine, but sometimes, it crashes after 4 images. Here's the code:


<title>jCarousel Examples</title>

<script type="text/javascript" src="../lib/jquery-1.4.2.min.js"></script>

<script type="text/javascript" src="../lib/jquery.jcarousel.min.js"></script>


<script type="text/javascript">

/**
 * This is the callback function which receives notification
 * when an item becomes the first one in the visible range.
 * Triggered before animation.
 */
function mycarousel_itemVisibleInCallbackBeforeAnimation(carousel, item, idx, state) {
    // No animation on first load of the carousel
    if (state == 'init')
        return;
        
    var first = idx;
    var center = idx-1;
    var last = idx-2;
    
    jQuery('.jcarousel-item-' + first + ' img').animate({ 
    width: "50%",
    height: "50%",
    opacity: 0.2,
    margin: "30px"
    }, 2000 );
    
    jQuery('.jcarousel-item-' + center + ' img').animate({ 
    width: "100%",
    height: "100%",
    opacity: 1.0,
    margin: "0px"
    }, 2000 );

    
    jQuery('.jcarousel-item-' + last + ' img').animate({ 
    width: "50%",
    height: "50%",
    opacity: 0.2,
    margin: "30px"
    }, 2000 );
};

/**
 * This is the callback function which receives notification
 * when an item becomes the first one in the visible range.
 * Triggered after animation.
 */
function mycarousel_itemVisibleInCallbackAfterAnimation(carousel, item, idx, state) {};


jQuery(document).ready(function() {
    jQuery('#mycarousel').jcarousel({
        vertical: true,
        scroll: 1,
        auto: 1,
        wrap: 'circular',
        animation: 2000,
        buttonPrevHTML: null,
        buttonNextHTML: null,
        itemVisibleInCallback: {
            onBeforeAnimation: mycarousel_itemVisibleInCallbackBeforeAnimation,
            onAfterAnimation:  mycarousel_itemVisibleInCallbackAfterAnimation
        }
    });
});

</script>
<style>
    #mycarousel img{
        width: 0%;
        height: 0%;
        opacity: 0.0;
        margin: 30px;
    }
</style>


I tried to relax on the animation features. It only freeze at another slide.

Any idea? Pre-load? It works fine at 100% on FF and IE...

Missing last item (LI) in my list

Hi,

I wonder if you can help. I am trying to use the carousel in a slightly different way; with one item visible at once. The issue I get is that it doesn't show the last item in the list (heading 'Integration').
You can see an example here:
http://204.12.125.58/
I havn't made any modifications to the js.
The page should be clean xhtml.
I have tried replacing the list content so its just item1, item2, item3 (plain text) but that didn't help.
There is a second issue that if you hit the next button about 10 times then it slows and eventually looks to be crashing (firefox reports that a script is taking to long to execute and offers to kill it).
I imagine the two issues are related. Is it simply because it's not been designed to have so few list items and one list item showing?

Thanks for help in advance

Steve

External Plugin Support

Feature request.
Event: If a plugin causes an event (most likely click) on an image that is outside the visible area for the carousel
Effect: carousel will scroll to the image the event was triggered on.

External controls and autoscroll count

Hi. I've created a carousel and have noticed that clicking external controls doesn't appear to reset the autoscroll count, so if the interval is 7 seconds, and you click a control when the count is around 5, the control-activated event occurs, followed quickly by the autoscroll-activated event. Is there any way to avoid this? Posted the script I'm using below. Thanks for any help, everyone. --cg

<script type="text/javascript">
<!--
function homecarousel_initCallback(carousel)
{
// Disable autoscrolling if the user clicks the prev or next button.
carousel.buttonNext.bind('click', function(){
carousel.startAuto(0);
});

carousel.buttonPrev.bind('click', function(){
    carousel.startAuto(0);
});

// Pause autoscrolling if the user moves with the cursor over the clip.
carousel.clip.hover(function(){
    carousel.stopAuto();
}, function(){
    carousel.startAuto();
});

jQuery('.jcarousel-control a').bind('click', function(){
    carousel.scroll(jQuery.jcarousel.intval(jQuery(this).text()));
    return false;
});

jQuery('.jcarousel-scroll select').bind('change', function(){
    carousel.options.scroll = jQuery.jcarousel.intval(this.options[this.selectedIndex].value);
    return false;
});

};

jQuery(document).ready(function(){
jQuery('#homecarousel').jcarousel({
auto: 7,
scroll: 1,
animation: 'slow',
wrap: 'circular',
initCallback: homecarousel_initCallback
});
});

-->
</script>

containers are moved below carousel

I'm designing a website that has 2 div containers directly beneath my (simple) carousel. For some reason I believe the javascript code associated with the carousel function is causing these 2 div containers to be pushed far below where the site is supposed to end on the page. I removed the 2 javascript documents from the site and the bug disappears. I only notice this on IE (6,7,8). Could you please help me to fix it?

Images not loading in Safari

I had a situation where I placed a jcarousel inside a jquery dialog and initialised the images in the carousel with itemLoadCallback. This worked fine on FireFox and IE but failed to load the images on Safari. In fact jCarousel simply would not invoke the itemLoadCallback on Safari (it did call the initCallback interestingly...).

My solution was to comment out the Safari specific lines at the bottom of the jCarousel constructor (in jcarousel.js) as follows:
//if (!windowLoaded && $.browser.safari) {
// this.buttons(false, false);
// $(window).bind('load.jcarousel', function() { self.setup(); });
//} else
this.setup();

So anyone else having this issue (affects Safari running on all of Mac, iPhone and iPad) this hack will fix it.

How do you auto scroll without the pause

Is it possible to configure the plugin to auto scroll without the pauses in between the scrolling? Essentially make it continuously scroll in a circular manner without ever pausing.

Thanks

HTML5 video embeds within a jCarousel breaks control/playback

I have a jCarousel that works great on the desktop (safari, firefox, etc) that has both images and HTML5 video.

However when viewing this on the iPad (or iPhone) the controls don't show up (the big play button in the middle of the frame). However, if I disable jCarousel and allow the LI's (the individual elements) just to flow down the page and the play button does show up.

Has anyone experienced this or know of somewhere to start looking to debug this? Here are the example screen shots:

Not working within jCarousel http://dl.dropbox.com/u/794440/Photo%20Sep%2024%2C%204%2039%2015%20PM.jpg

Working when commenting out the .jCarousel(); initialization
http://dl.dropbox.com/u/794440/Photo%20Sep%2024%2C%204%2042%2020%20PM.jpg

Markup is not "translated" when content type is application/xml

Hello,

I have a problem with jcarousel. I started creating a Webinterface with content type text/html. Everything worked fine (I used jcarousel to make some rotating country flags to change the language). Now I have to add some svg to the interface, and thus changed the content type to application/xml. The result is, that I see an "standard" list with bullet points and the flags after it, but no carousel.

When looking in Firebug, the outcome was:

<div class=" jcarousel-skin-tango">
    <ul id="mycarousel" class="jcarousel-container jcarousel-container-horizontal" style="position: relative; display:block;">
        <li><img src="gb.png" width="16" height="11" alt="English" class="language"/></li>
        [...other images here]
    </ul>
</div>

As I am not really an experienced web-designer, I am a little lost here. Any help would be much appreciated.

Michael

Width/height issue in Chrome

With jCarousel 0.2.5, Chrome users get the error "Uncaught Error: jCarousel: No width/height set for items. This will cause an infinite loop. Aborting...". Tracing the code, I found this is a result of a bug in WebKit (and therefore Chrome). See http://code.google.com/p/chromium/issues/detail?id=18418. This bug should resolve itself once this bugfix is incorporated into Chrome, but maybe you can provide a workaround until then. The problem occurs on line 849 of jquery.jcarousel.js:

            (el.offsetWidth || $jc.intval(this.options.itemFallbackDimension)) + $jc.margin(el, 'marginLeft') + $jc.margin(el, 'marginRight') :

In Chrome, offsetWidth is 0, but should be the actual width.

jcarousel image

Hi all I am using jcarousel for my application and i am completely new to this..In my application i am also using jquery tabs .The main logic is when i click on a tab there should be 3 visible images .I have 4 tabs the carousel is showing exactly when i click on the first tab ,but when i click on the other tabs the image is getting clipped and it is showing just a part of the 1st image
please somebody help me on this issue

Extra <li>s

Dynamically loaded jCarousel creates extra

  • when do data is returned or the data is less than the size parameter.

    This causes the css hover to activate on "blank" elements.

  • Scroll reduces with every pressing of next button.

    Hi,

    I am really frustrated with one error and would be really thankful if you can help / assist me in any way.

    What happens is that, in CHROME, that the list of images are shown perfectly in the horizontal direction. The problem occurs, when I press the Next Button.

    With one image moving at a time ( scroll: 1) from right to left, the most left image (first image to go) always stays a bit behind and doesn't fully go back. When I press the next button again, the second image to go does the same but it now stays behind double the space the previous one. This keeps on repeating with every next next button pressing.

    It is only happening in Chrome; not in Firefox.

    Please help; I will be very thankful.

    Loading jCarousel especially in IE6/7 is to slow so the list items can be seen while loading

    Hello.

    Thank you for that great plugin. We got a problem with the loading of jCarousel in IE6/7. The initialization process is so slow that the user can see the list items while initalizing jCarousel. Is there a possibility to show a loader icon while the plugin initalizes itself and hide the list items during that time? Or what would be the best way to handle that problem correctly.

    Regards and thank you very much.

    iPhone error

    jcarousel does not work with iPhone. When viewing my page via iPhone, I get an alert() error about width and height not set.

    Combine with Fading

    Hi, is it possible to combine sliding animation with a fading effect when first/last item enter or exit?

    Thanks

    Scrolling jumps when you scroll down several times and then up again in circular carousel

    I've set up a page with a vertical circular carousel with 10 thumbnails in it, showing around 5 at a time. When I scroll down 3-4 times, and then scroll up again, the whole carousel will move up above the last thumbnail (just showing the background) and then come flying back into place. If I keep scrolling up, it will start behaving correctly again when I'm back to around where I began scrolling down.

    If I scroll up 3-4 times, and then back down again, the same thing does not happen, which is kind of strange.

    I'm using Version 0.2.5.

    Problem with scroll on Safari/Chrome

    It's hard to say what i'm seeing. Even more because I'm from Brazil and don't speak a good English. Let me try.

    I'm building an app that has a menu (controled by jquery tabs) with a fixed width depending on the client's width screen. To scroll the menu I'm using your pluging, that's is nice.

    I have a situation where the user can add more tabs, and so i scroll (using the method scroll from the plugin) to that tab because it can be visible or not depending on the visible area from the client.

    The problem is that when i scroll on Safari/Chrome the plugin creates a blank area at the beginning of the menu, breaking everything.

    How i call scroll:
    Busca._jcarousel.scroll($(ui.tab).parent().attr("jcarouselindex"), true);

    I'm not sure if I's clear or not. If you need something, please let me know.

    Rodrigo.

    Set correct li.jcarousel-item width when visible option is given

    Hey, thanks a lot for jcarousel, it was just what we needed for a project.

    I found what seems to be a bug, though: if you don't set a width for li.jcarousel-item, jcarousel will create many items with a very small width. In my case, for a clipping of 820px, each item was 10px wide.

    What I think should happen is this: if you set the visible option, jcarousel should automatically calculate the right width for each item, even if no size is specified at first (because the elements will be loaded using ajax).

    Just to be clear for anyone that is hit by the same problem, the workaround is adding a width to the CSS specification of .jcarousel-item, like so

    .jcarousel-item {
      width: xxxpx; /* width for each individual item needs to be greater than the width the item will actually occupy */
    }
    

    Thanks,

    David

    putting this code in makes other JS not work

    hi, I have put in your code and the 'lightbox2' code on the same page and have got them both working separately, but not together on the same page (ie. if yours in working, the lightbox is not) can you advise?

    Width of <ul> doubling and quadrupling, making it 1.2732458e07px very soon

    There is a webpage where the <li> was styled all at the beginning, with correct width, but since the width was too big, about 15600px, and it caused IE to be very slow in rendering, so the carousel was changed to using Ajax, initially loading either 0 or 1 to 5 pages, and use Ajax to load the <li> afterwards.

    But the <ul> width was doubling and quadrupling after several click on "Next". The reason was that empty <li> was created as placeholder by jCarousel, and if it is not styled in CSS, then it took the width of the div, and add to the existing <ul> element. The width of the <ul> was reaching something like 1.2732458e07px, and this number is read on the CSS possibly as 1.27px, and the end result was that the carousel was empty.

    So if static carousel items, the <li> can be styled using its own class name or id names. If it is by Ajax, then a width need to be set for the <li> under the <ul>, something like

    .jcarousel-item { width: 130px }
    

    Not only a width is needed. If a height is not specified, then if your carousel can scroll to the "last page" initially, if those empty divs has a width but not a height, on Firefox, those div will not occupy any width at all, and so the last columns added will be at column 4, 5, 6 instead of column 32, 33, 34, (the last ones). So, also add something like:

    .jcarousel-item { width: 130px; height: 375px }
    

    Bad size of the last element of a carousel

    Hello,

    When I set a carousel, the calculation of the size of the last element is wrong. You can see it on this page (same as the last time :) ) : http://sxjpl.free.fr/blog2/
    The 2 carousels at the bottom left of the page (the ones called "Billets récents" and "Commentaires récents) have a 1 pixel problem (on the left on the carousel) when you go to the last item (using the "next" buttons on the top right of each carousel). It's on Firefox 3.6.8 (the last version).
    Unfortunately, it doesn't solve the problem if I set those carousels with "visible: 1"...

    Possible issue with reload method

    If the contents of jcarousel-item is made up from more ul/li tags, upon calling the reload method, the newly calculated width/height is being set to all li tags and not just to the "outer" li tags, that is to jcarousel-items, which, in the end results in braking the look of the items. This happens with both horizontal and vertical carousels.

    Note: this might be an issue caused by me, by not setting all widths and height correctly, if so, sorry for taking your time :)

    Minimum HTML code to reproduce:

    <ul id="vert" class="jcarousel-skin-tango">
        <li>
        <ul>
            <li><h2>Title 1</h2></li>
            <li><p>Text 1 dummy content</p></li>
        </ul>
        </li>
        <li>
        <ul>
            <li><h2>Title 2</h2></li>
            <li><p>Text 2 dummy content</p></li>
        </ul>
        </li>
            <li>
                <ul>
                    <li><h2>Title 3</h2></li>
                    <li><p>Text 3 dummy content</p></li>
                </ul>
            </li>
        </ul>
    
        $(document).ready(function(){
            $('#vert').jcarousel({
                        auto: 4,
                        scroll: 1,
                        visible: 2,
                        vertical: false,
                        wrap: 'last',
                        buttonNextHTML: null,
                        buttonPrevHTML: null
                    });
                });
    

    To see the "bug" happening, open a jcarousel example in a maximized window and then unmaximize it, so the reload method is fired. The height of the jcarousel-item will be applied to all li elements in the jcarousel.

    My workaround is to change line 280 in jquery.jcarousel.js from:

    $('li', this.list).each(function(i) {
    

    to:

    $('li.jcarousel-item', this.list).each(function(i) {
    

    Cheers!

    Issue with RTL support

    Thanks for creating this amazing script. I am working on an Arabic website and I recently found that RTL support was added as per an article on rtling.com

    So when I use this feature, I came across following two issues -

    1. The Right and Left navigation buttons still behave as if its a LTR page and therefore when the widget loads, the right button is enabled and left button is disabled leading to issues when clicked.
    2. The elements inside the widget starts from last index rather that the first index on the right (probably the elements needs to be added in a reverse order inside the container).

    I am hoping this issue will be fixed soon :)

    vertical auto scolling doesn't clean up dom

    Hi, I am implementing jcarousel using {vertical:true, wrap:'circular', auto:1} . Looking at the DOM in the Firebug DOM inspector jcarousel appears to be appending the UL with a new set of li elements but it doesn't appear to be cleaning up the li's that have been displayed.

    I have posted an example here
    http://www.de-saxe.id.au/jcarousel/

    If you have any questions my git hub name is julian-de-saxe

    Kind regards,

    example using external controls with Ajax?

    is there an example of jCarousel using external controls and Ajax paginated images?

    I've been trying to implement this but the external controls don't work. I presume it's because itemLoadCallback which binds the next and prev buttons runs before itemFirstInCallback wich pulls the first set of images.

    Does anyone have an idea?

    JSLINT

    I shouldn't whine about this as it is free and all, my issue is merely a suggestion. Could you format your code to be 100% valid for JSLINT, please? It is only a suggestion, so I (and maybe more others) wouldn't have to reformat the whole code accordingly at every release. Thank you for your hard work!

    jCarousel : automatic prev/next bug

    Hello,
    I have 4 carousels on my homepage. They are set with like this :
    jQuery(document).ready(function() {
    jQuery('#carousel-lastposts').jcarousel({
    scroll: 1,
    animation: 0,
    buttonPrevHTML: '<',
    buttonNextHTML: '>'
    });
    jQuery('#carousel-lastcomments').jcarousel({
    scroll: 1,
    animation: 0,
    buttonPrevHTML: '<',
    buttonNextHTML: '>'
    });
    jQuery('#carousel-lastevents').jcarousel({
    scroll: 1,
    animation: 0,
    buttonPrevHTML: '<',
    buttonNextHTML: '>'
    });
    jQuery('#carousel-lastimages').jcarousel({
    scroll: 4,
    buttonPrevHTML: '<',
    buttonNextHTML: '>',
    itemLoadCallback: carousel_lastimages_itemLoadCallback
    });
    });

    If I replace default controls with external controls, it works like a charm... But using default controls doesn't work at all : for example, the first carousel has 6 items ; if I click on the "next" button, I see item #6. And if I click on the "previous" button, it scrolls to #1...
    Now it's not a CSS problem, since I've tried to disable CSS, and the problem is the same (I mean : for example the "next" button is set to "disabled='true'" as soon as I click on it, whereas it shouldn't since there are 6 items to scroll...)
    So.. maybe this is a bug ? Thanx very much for your help,
    Dupond

    Carousel repeats same slide.

    The carousel worked well until I added a third entry and now it will only show the first 'slide'.

    It will do the sliding animation but show the same, first, page.

    Any advice?

    PS:
    I may have partially fixed the issue by adding a fourth slide. But I am still curious if anyone has encountered and/or solved this?

    Using tooltips with jCarousel...

    I'm trying to add an explanation tooltip for each image in the carousel, using the Beautytips jQuery plugin (http://plugins.jquery.com/project/bt), but it fails after a while (i think that it begins to fail when carousel objects are being created and destroyed for circular mode).

    Can anyone give me a tip to use BT or any other tooltips with jCarousel?

    thanks in advance, kind regards,

    Error when set start position

    I'm gettig error "Error: jCarousel: No width/height set for items...", when I set start index > 1 (no problem for start = 1) in this example:
    http:doubleslash albion.dev.intya dot cz/jcarousel-bug.html
    (i.e. when it is impossible to scroll start item to the left margin of the carousel).

    I expect that in this case carousel should scroll to the left as much as possible even if the start item would not be on the outermost left.

    I also found out, that error magically disappears if i set margin to items. But for start=4, the item "Two" is on the start position and the item "Four" stays partially hidden.

    Tested in FF 3.5.11

    Same content over and over

    I'm using 6 carousels on the same page, all of them get content via ajax.

    My problem is that at some point, while waiting with the page open on the browser, the carousels will show the first "row" of content over and over again.

    For example: a carousel with 4 viewable items and another 4 items hidden, starts on page load by showing the first 4 and then automatically scrolls to the next 4. This works fine for some time, but at some point the carousel will switch from viewing the first 4 items again to the first 4 items, so it still has 8 items, but they are all the same first 4.

    IE7 and IE6 Problems with Multiple Carousels

    thanks to the developer for posting this first of all

    I am currently using 4 of these on a development site (url below) but the first 2 do not scroll in early versions of IE7 and below ... or IE8 in compatibility mode

    http://moe.owen.edu/vanderbilt/newsroom/multimedia-gallery/

    all 4 are ID uniquely but otherwise coded the exact same way

    the one way I have been able to make it work is to reduce the width of the container div in the CSS by about 200 pixels or so ... but I can not understand why that makes a difference

    any help or insight is appreciated

    thanks

    Carlos

    circular wrap doesn't work

    Isn't circular supposed to go like in this order:
    Slide1
    Slide2
    Slide3
    Slide4
    Slide5
    Slide6
    Slide7
    Slide1
    Slide2
    and so on...

    If I set it to automatic and wrap circular, it stops at Slide7.

    Filter jcarousel content

    Hello!

    I don't know if it's a bug or not, but here's my problem: I filter the jcarousel content using jquery. Everything goes ok until i start to use the next/prev buttons. On the default stage of filtering, buttons are working ok, but after i start to filter the content (images) the jcarousel start to work all crazy. For example, if i have 10 images in default state, showing 3 on stage, after filtering (let's say i have only 4 now) if i get to the last picture, the next button it's still enabled and i can scroll another 10-15px area even there is only blank space.

    Images that are removed by the filter are going out by fadeOut animation.

    I tried to call the jcarousel after every filtering action but i get the same result. In some cases, after i apply the filter, the prev btn. it's not enabled but i can scroll 100-200px area of blank space.

    I tried to solve this issue for the last 3 days but i couldn't find the right solution.

    Sorry for my english and thanks :-)

    Duplication of LI elements when wrap: 'circular'

    So I'm loving jCarousel so far and I'm planning to utilize it on a site I'm currently working on. I'm particularly interesting in the vertical mode with a 'circular' wrap, but I'm noticing something I think is odd. I just want to make sure I'm not doing something to cause it....

    When the vertical carousel reaches the bottom of the

  • list, it adds the first
  • to the bottom of the list so that it scrolls into place. That is working fine, but the
  • is left at the top of the list. If you repeat through the list multiple times, the entire list is duplicated over and over again. After 10 complete vertical cycles, you've got 10 times the number of
  • elements you start with. Is this by design? Or is there something that might be setting it off?

    I would have assumed that the first

  • gets pulled off the top of the list and then moved to the bottom (and vice versa when you're going the other direction) rather than duplicated. My issue is that I have complicated tooltip-type popups tied to the
  • elements and it seems to get confused as to which
  • triggered the popup. They frequently popup adjacent to a
  • that has long since scrolled out of view.

    Thanks!

    ..jon

  • Recommend Projects

    • React photo React

      A declarative, efficient, and flexible JavaScript library for building user interfaces.

    • Vue.js photo Vue.js

      🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

    • Typescript photo Typescript

      TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

    • TensorFlow photo TensorFlow

      An Open Source Machine Learning Framework for Everyone

    • Django photo Django

      The Web framework for perfectionists with deadlines.

    • D3 photo D3

      Bring data to life with SVG, Canvas and HTML. 📊📈🎉

    Recommend Topics

    • javascript

      JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

    • web

      Some thing interesting about web. New door for the world.

    • server

      A server is a program made to process requests and deliver data to clients.

    • Machine learning

      Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

    • Game

      Some thing interesting about game, make everyone happy.

    Recommend Org

    • Facebook photo Facebook

      We are working to build community through open source technology. NB: members must have two-factor auth.

    • Microsoft photo Microsoft

      Open source projects and samples from Microsoft.

    • Google photo Google

      Google ❤️ Open Source for everyone.

    • D3 photo D3

      Data-Driven Documents codes.