javascript - jQuery Tabs activate on Carousel with Mobify -


i need able have tab menu above carousel, when clicked on move carousel associated package within carousel.

also when carousel swiped tabs move accordingly package swipe to. active tab change if swipe , vise-versa.

i have put demo, working apart linking tabs , carousel. totally lost @ how this.

my demo code , example: - http://jsfiddle.net/jnys7/

<ul id="navlist">    <li>basic</li>    <li class="activestep">standard</li>    <li>super</li>    <li>antoher</li> </ul> 

plugin using: http://www.mobify.com/mobifyjs/modules/carousel-examples/

hope can out. thanks

an example: http://jsfiddle.net/jnys7/3/

what did move #navlist inside of .m-carousel , added <a> data-slide='number_here' attribute <a>, making pagination. changed activestep class name m-active.

now need style it.

update http://jsfiddle.net/jnys7/10/

change margin-right here define distance between divs

.m-center:not(.m-fluid) > .m-carousel-inner > *:not(:first-child), .m-center:not(.m-fluid) > .m-carousel-inner > *:not(:last-child){     position: relative;     float: left;     left:40px;     margin-left:0px;     margin-right:-30px; } 

i didn't find reference starting point can use .trigger() jquery trigger click event on link

$('#navlist li:eq(2) a').trigger('click');  //:eq() index of li (in case super) 

in updated fiddle changed css in overall, compare fiddle missing css.


Comments

Popular posts from this blog

SPSS keyboard combination alters encoding -

Socket.connect doesn't throw exception in Android -

iphone - How do I keep MDScrollView from truncating my row headers and making my cells look bad? -