I have implemented jCarousel dynamically loading images with AJAX. It runs fine until I click some other link on the page and it shows me the following error: "jCarousel: No width/height set for items. This will cause an infinite loop. Aborting..."
Below is the part of the code what I am using: function gallery() { $('#cbody').html('<div id="mycarousel" class="jcarousel-skin- tango"><ul></ul></div><div style="padding:10px;align:center" id="dspPic"></div>'); $('#mycarousel').jcarousel({ scroll: 6, itemLoadCallback: mycarousel_itemLoadCallback }); }; function mycarousel_getItemHTML(url) { var url_m = url.replace(/small/g, ''); return '<a href="javascript:showPic(' + "'" + url_m + "'" +')"><img src="' + url + '" width="75" height="75" border="0"/></a>'; }; function showPic(picurl) { $('#dspPic').html("<img src='" + picurl + "' border='0' / >").animate({height: 'show', opacity: 'show'}, 'slow'); } Thanks!