stephmoreland
stephmoreland

Reputation: 4163

Nivo slider: Click first slide to start

Nivo Slider for jQuery: I'm sure I'm missing something, but is there a way to have the slider start and loop by clicking on the first image? I have a series of 8 images that I'm replacing an SWF with, but the first slide says "Click to start". I know I can turn on the manual option, but that's not what I need. I just need the slider to start it's loop when the first image is clicked.

Upvotes: 0

Views: 1662

Answers (2)

Pascal
Pascal

Reputation: 1

Or you can put the following in the head section:

<script type="text/javascript">
   jQuery(window).load(function() {
   $('#Slider').data('nivoslider').stop();
   $('#Slider').live('click', function() {$('#Slider').data('nivoslider').start();});
    });
</script>

Upvotes: 0

Zoltan Toth
Zoltan Toth

Reputation: 47667

Probably you have to set the manualAdvance: true - look at the complete list of options here.

And then just attach a click event listener to the slideshow/first slide and set the manualAdvance back to false, so it can continue to play

Upvotes: 1

Related Questions