Using bootstrap carousel.js to realize the animation effect _javascript skill of the carousel graph

Source: Internet
Author: User
Tags bootstrap carousel

Pre-Preparation:

1.jquery.js.

2.bootstrap of Carousel.js.

3.bootstrap.css.

Let's look at the code together:

The page is ugly, I hope you don't mind oh hee

Effect Chart:

HTML+JS:

<!  DOCTYPE html>  

Index.css

 Container-fluid {padding-left:200px;}. Navbar-default {background-color: #308dca;}
 . navbar-brand {font-size:34px;
height:70px; }. Navbar-nav>li>a {font-size:19px}. navbar-default. Navbar-brand,. Navbar-default. Navbar-nav>li>a,. na Vbar-default navbar-nav>li>a:hover,. Navbar-default. Navbar-nav>li>a:focus {color: #fff;} navbar-brand ,. navbar-nav>li>a {line-height:40px}. navbar-default. navbar-nav>.active>a,. Navbar-default.
 Navbar-nav>.active>a:hover, Navbar-default. Navbar-nav>.active>a:focus {color: #fff;
Background-color: #2276bf; }. index-body {margin:0 auto; carousel-inner {height:490px;}. Index-body,. Images {width:900px}. index-foot
 er {margin-top:20px;
 Color: #fff;
Background-color: #2276bf;
 }. footer-centent {width:300px;
 font-size:20px;
 line-height:55px;
 margin:0 Auto;
height:60px; }

Everyone in their own design demo time, note that class for Index-body div and the width of the IMG to set the same, otherwise there will be the following:

The above is a small series to introduce the use of bootstrap carousel.js to achieve the animation effect of the carousel, I hope to help you, if you have any questions please give me a message, small series will promptly reply to everyone. Here also thank you very much for the cloud Habitat Community website support!

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.