Sure, try the below modified contentslider.js file, which adds a new public method:
Code:
featuredcontentslider.playpause('sliderid', 'play|pause')
The first parameter of the method should be the ID of the slider (same ID used in the initialization code of the slider in question), and the second, a string of either "play" or "pause". This method when called either pauses or plays the slider in question. For example, given a slider with the following initialization code:
Code:
<script type="text/javascript">
featuredcontentslider.init({
id: "slider1", //id of main slider DIV
contentsource: ["inline", ""], //Valid values: ["inline", ""] or ["ajax", "path_to_file"]
toc: "#increment", //Valid values: "#increment", "markup", ["label1", "label2", etc]
nextprev: ["Previous", "Next"], //labels for "prev" and "next" links. Set to "" to hide.
revealtype: "click", //Behavior of pagination links to reveal the slides: "click" or "mouseover"
enablefade: [true, 0.2], //[true/false, fadedegree]
autorotate: [true, 1000], //[true/false, pausetime]
onChange: function(previndex, curindex){ //event handler fired whenever script changes slide
//previndex holds index of last slide viewed b4 current (1=1st slide, 2nd=2nd etc)
//curindex holds index of currently shown slide (1=1st slide, 2nd=2nd etc)
}
})
</script>
The below two links when clicked on dynamically plays/ pauses the slider:
Code:
<a href="javascript:featuredcontentslider.playpause('slider1', 'play')">Play</a> <a href="javascript:featuredcontentslider.playpause('slider1', 'pause')">Pause</a>
In your case, you'd just call this method when the tab script is clicked on.
Bookmarks