自适应幻灯片 - 如何向幻灯片添加按钮

时间:2014-03-10 05:33:57

标签: jquery responsive-slides

我正在使用responsive slides作为我的客户端项目。我需要在带有链接的滑块图像上添加“阅读更多”按钮。我搜索了谷歌和stackoverflow以获得期待的答案。所以我决定问一个问题。下面我添加了我目前为滑块所做的代码。我是Javascript和JQuery的新手。

<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js"></script>
<script src="responsiveslides.min.js"></script>
<link rel="stylesheet" src="responsiveslides.css"></link>
<div class="rslides_container">
  <ul class="rslides" id="slider">
    <li><img src="1.jpg" alt=""></li>
    <li><img src="2.jpg" alt=""></li>
    <li><img src="3.jpg" alt=""></li>
  </ul>
</div>

<script>
    $(function () {
        $("#slider").responsiveSlides({
            auto: true,
    pager: true,
    pause: true,           // Boolean: Pause on hover, true or false
    pauseControls: true,    // Boolean: Pause when hovering controls
            nav: true,
            speed: 500,
            maxwidth: 800,
    manualControls: "",     // Selector: Declare custom pager navigation
    namespace: "rslides",   // String: Change the default namespace used
    before: function(){},   // Function: Before callback
    after: function(){}     // Function: After callback
        });
     });
</script>

0 个答案:

没有答案