Now there's the "rev" option that will do this work for you. Setting it to 1 or true, should do the trick:
Change sliding direction for scrollHorz
-
07-08-2022 - |
Question
I am using jquery cycle, the scrollHorz effect. I know that it has a rev option for change the scroll direction. By default it scrolls left for the previous slide and right for the next slide, but I want scrolling right for the previous slide and left for the next slide. Everything works fine except this and I don't find any answer. Everywhere is the rev option only. Any help would be appreciated! Thx
PS: Sorry for my English, I hope my problem is understandably.
So, here is the HTML code:
<div id="bup">
Some text
<div id="bfullnav">
<div id="bnavback"><<</div>
<div id="bnav"></div>
<div id="bnavfw">>></div>
</div>
</div>
<div id="bdown">
<div id="btext">
<div id="t1">Some text</div>
<div id="t2">Some text</div>
<div id="t3">Some text</div>
<div id="t4">Some text</div>
<div id="t5">Some text</div>
<div id="t6">Some text</div>
</div>
</div>
The js:
$('#btext').cycle(
{
fx:'scrollHorz',
speed: 2000,
next: '#bnavfw',
prev: '#bnavback',
timeout: 0,
pager: '#bnav',
rev: true,
});
When I click on the #bnavfw or one of the pager with higher value, it scrolls the text to the right and vice versa. But I would like to scroll to the left for the next, and right for the back.
No correct solution
OTHER TIPS
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow