Small Auto scrolling Carousel Plugin with jQuery yac js - Download Small Auto-scrolling Carousel Plugin with jQuery - yac.js

Download Small Auto-scrolling Carousel Plugin with jQuery – yac.js

Posted on

This time I will share jQuery Plugin and tutorial about Small Auto-scrolling Carousel Plugin with jQuery – yac.js, hope it will help you in programming stack.

Small Auto scrolling Carousel Plugin with jQuery yac js - Download Small Auto-scrolling Carousel Plugin with jQuery - yac.js
File Size: 4.98 KB
Views Total: 2308
Last Update:
Publish Date:
Official Website: Go to website
License: MIT
   

yac.js (yet another carousel) jQuery plugin allows you to create a non-stop image carousel with bottom slide indicators.

How to use it:

1. Insert a group of images into the carousel following the html structure like this:

1 <div class="yac">
2   <div class="yac-inner">
3     <div class="active"><img src="1.png" alt=""></div>
4     <div><img src="2.png" alt=""></div>
5     <div><img src="3.png" alt=""></div>
6   </div>
7 </div>

2. Include jQuery library and the jQuery yac.js plugin at the bottom of the web page.

1 <script src="jquery-1.11.3.min.js"></script>
2 <script src="yac.js"></script>

3. Basic CSS styles for the carousel.

01 .yac {
02   width: 1000px;
03   height: 500px;
04   position: relative;
05   overflow: hidden;
06 }
07  
08 .yac-inner div {
09   position: absolute;
10   top: 0;
11   left: 0;
12   z-index: 0;
13 }
14  
15 .yac-inner .active { z-index: 1; }

4. Style the slide indicators.

01 .yac-indicators {
02   position: absolute;
03   padding: 0;
04   bottom: 0px;
05   width: 100%;
06   text-align: center;
07   z-index: 100;
08 }
09  
10 .yac-indicators li {
11   display: inline-block;
12   width: 10px;
13   height: 10px;
14   border: 2px solid #fff;
15   border-radius: 10px;
16   margin: 2px;
17   cursor: pointer;
18 }
19  
20 .yac-indicators li.active { background-color: #fff; }

5. Initialize the carousel and setup the transition speed you prefer.

1 Yac(2000); // default: 5000ms

This awesome jQuery plugin is developed by chrisktaylor. For more Advanced Usages, please check the demo page or visit the official website.

source : jqueryscript.net