Large Bootstrap Carousel

Images courtesy of Pixabay.

This example fills any container it is in and scales beautifully from large screen down to cell phone screen.



HTML Code


<%--Begin carousel container--%>
    <div style="border: 2px solid #033769; border-radius: 4px; overflow:hidden">
        <div id="myCarousel" class="carousel slide" data-ride="carousel" data-interval="4000" data-pause="hover">
            <!-- Indicators -->
            <ol class="carousel-indicators">
                <li data-target="#myCarousel" data-slide-to="0" class="active"></li>
                <li data-target="#myCarousel" data-slide-to="1"></li>
                <li data-target="#myCarousel" data-slide-to="2"></li>
            </ol>
           <div class="carousel-inner" role="listbox">
                <div class="item active">
                    <img src="images/10-15-16-carousel/earth.jpg" alt="The Earth" />
                    <%--<div class="container">--%>
                    <div class="carousel-caption">
                        <p style="font-size: 20px; font-weight: bold;">The Earth</p>
                        <p>The world we live in.</p>
                        <a href="#" class="btn btn-default btn-xs">Learn more</a>
                    </div>
                    <%--</div>--%>
                </div>
                <div class="item">
                    <img src="images/10-15-16-carousel/moon.jpg" alt="The Moon" />
                    <%--<div class="container">--%>
                    <div class="carousel-caption">
                        <p style="font-size: 20px; font-weight: bold;">The Moon</p>
                        <p>Our nearest neighbor.</p>
                        <a href="#" class="btn btn-default btn-xs">Learn more</a>
                    </div>
                    <%--</div>--%>
                </div>
                <div class="item">
                    <img src="images/10-15-16-carousel/sun.jpg" alt="The Sun" />
                    <%--<div class="container">--%>
                    <div class="carousel-caption">
                        <p style="font-size: 20px; font-weight: bold;">The Sun</p>
                        <p>The center of our solar system.</p>
                        <a href="#" class="btn btn-default btn-xs">Learn more</a>
                    </div>
                    <%--</div>--%>
                </div>
            </div>
            <a class="left carousel-control" href="#myCarousel" role="button" data-slide="prev">
                <span class="glyphicon glyphicon-chevron-left" aria-hidden="true"></span>
                <span class="sr-only">Previous</span>
            </a>
            <a class="right carousel-control" href="#myCarousel" role="button" data-slide="next">
                <span class="glyphicon glyphicon-chevron-right" aria-hidden="true"></span>
                <span class="sr-only">Next</span>
            </a>
        </div>
    </div>
 <%--end carousel container--%>

            

Categories

Technology  

The saddest aspect of life right now is that science gathers knowledge faster than society gathers wisdom.
~Isaac Asimov

Learn more »


Education  

Education must not simply teach work; it must teach Life.
~W. E. B. Du Bois

Learn more »


On the Web  

The Internet is the trailer park for the soul.
~Marilyn Manson

Learn more »


Christianity  

I gave in, and admitted that God was God.
~C. S. Lewis

Learn more »


Books  

So many books, so little time.
~Frank Zappa

Learn more »


Music  

Ah, Bach! I'm partial to the fugue.
~Walter Radar O'Reilly

Learn more »


Sports  

You can observe a lot by watching.
~Yogi Berra

Learn more »


Projects  

The best-laid schemes o' mice an' men Gang aft agley, An' lea'e us nought but grief an' pain, For promis'd joy!
~Robert Burns

Learn more »