jQuery

【jQuery】jQueryスライダープラグインLinear Slider

November 26, 2016
Linear Slider

Linear SliderはjQueryを使用したスライダープラグイン。

JS&CSS

<head>
    <title>Linear Slider</title>
    <link href="css/style.css" rel="stylesheet" />
    <link href="css/slide.css" rel="stylesheet" />
    <link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" rel="stylesheet">    
    <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.4/jquery.min.js"></script>
    <script src="js/linear-slider.js"></script>
    <script>
        $(document).ready( function() {
            $('#slide').linearSlider();
        });
    </script>
</head>

Slider

        <div id="slide">
            <div id="slide-content">
                <ul>
                    <li>Slide #1</li>
                    <li>Slide #2</li>
                    <li>Slide #3</li>
                    <li>Slide #4</li>
                    <li>Slide #5</li>
                </ul>
            </div>
            <div id="slide-nav">
                <ol></ol>
            </div>        
        </div>