//var run = setInterval(rotate, speed);
var slides = $('.slide');
var container = $('#slidesText ul');
var elm = container.find(':first-child').prop("tagName");
var item_width = container.width();
var previous = 'prev'; //id of previous button
var next = 'next'; //id of next button
slides.width(item_width); //set the slides to the correct pixel width
container.parent().width(item_width);
container.width(slides.length * item_width); //set the slides container to the
container.find(elm + ':first').before(container.find(elm + ':last'));
var listCount =3;
if(listCount != 1){
resetSlides();
}
/* Stop looping carousel*/
var firstList = container.find(elm + ':first').attr('id');
var lastList = container.find(elm + ':last').attr('id');
var showingSlide = container.find(elm + ':nth-child(1)').attr('id');
/* Stop looping carousel end*/
$('#carousel a').on('click', function (e) {
//slide the item
console.log('debug')
var serviceId
if (container.is(':animated')) {
return false;
}
if (e.target.id == previous) {
$('#carousel #next').css('pointer-events','initial')
$('#carousel #next').css('border-color','#3c8aa0');
serviceId=container.find(elm + ':first').attr('id');
container.stop().animate({
'left': 0
}, 1500, function () {
container.find(elm + ':first').before(container.find(elm + ':last'));
...
Please Whitelist JSFiddle in your content blocker.
Help keep JSFiddle free for always by one of two ways:
Whitelist JSFiddle in your content blocker (two clicks)
Go PRO and get access to additional PRO features →
Join the 4+ million users, and keep the JSFiddle dream alive.
Ad-free
All ads in the editor and listing pages are turned completely off.
Use pre-released features
You get to try and use features (like the Palette Color Generator) months before everyone else.
Fiddle collections
Sort and categorize your Fiddles into multiple collections.
Private collections and fiddles
You can make as many Private Fiddles, and Private Collections as you wish!
Console
Debug your Fiddle with a minimal built-in JavaScript console.