0

我有两个 jQuery Cycles 版本 2。http://jquery.malsup.com/cycle2/ 我想要一个导航 (#nav) 来控制两个周期。我知道它仍然是测试版,所以也许还不可能..

    <script src="http://jquery.malsup.com/cycle2/jquery.cycle2.js"></script>
    <script src="http://jquery.malsup.com/cycle2/jquery.cycle2.scrollVert.js"></script>

    <div class="cycle-slideshow"
        data-cycle-fx="scrollVert"
        data-cycle-pause-on-hover="true"
        data-cycle-timeout="0"
        data-cycle-pager="#nav">
        <img src="http://i46.tinypic.com/29oocgm.jpg" data-cycle-pager-template="<a href=#>1</a>" />
        <img src="http://i48.tinypic.com/o602sz.jpg" data-cycle-pager-template="<a href=#>2</a>" />
        <img src="http://i50.tinypic.com/qntoxc.jpg" data-cycle-pager-template="<a href=#>3</a>" />
    </div>
    ​&lt;br />
    <br />
    <div class="cycle-slideshow"
        data-cycle-fx="scrollVert"
        data-cycle-pause-on-hover="true"
        data-cycle-timeout="0"
        data-cycle-pager="#nav">
        <img src="http://i46.tinypic.com/29oocgm.jpg" data-cycle-pager-template="<a href=#>1</a>" />
        <img src="http://i48.tinypic.com/o602sz.jpg" data-cycle-pager-template="<a href=#>2</a>" />
        <img src="http://i50.tinypic.com/qntoxc.jpg" data-cycle-pager-template="<a href=#>3</a>" />
    </div>
    <div id="nav"></div>​​​​​​​​​​​​​​​​​​​​​​​​​​​​​​​​​

示例:http: //jsfiddle.net/hfjXd/

4

1 回答 1

0

我不确定我是否完全理解你的意思,但如果你只是使用:

data-cycle-prev=".prev"
data-cycle-next=".next"

在这两个周期上,它都应该这样做。

检查这个例子:查看源: http: //jquery.malsup.com/cycle2/demo/caro-pager.php 和这个:http: //jquery.malsup.com/cycle2/demo/prevnext.php

于 2013-05-27T08:32:16.383 回答