I have many jQuery SlidesJS in different jQuery tabs. Works great. My problem now is, when I click on tab2 with slide2 and I'm going back to tab1 with slide1, I want to restart slide1 at 1! My code for this is:
<script>
function start(_start) {
if(_start != "") {
starter = _start;
} else {
starter = 1;
}
$('#slides1, #slides2, #slides3').slides({
start: starter,
preload: true,
slideSpeed: 1000,
play: 4000,
pause: 2000,
slideEasing: 'easeInOutQuint',
generateNextPrev: false,
pagination: false,
next: 'next',
prev: 'prev'
});
$("#tabs").tabs();
}
$(document).ready(function() {
start(1);
$("#ui-id-1").click(function(){
start(1);
});
});
</script>
#ui-id-1 is tab1. Clicking on it is should start slide1 at 1. But what I get is a blank white div. Any ideas how to start at 1 when I click on the tab?