Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums JavaScript Syntax Error Re: Syntax Error

#104100
Taufik Nurrohman
Participant

I tried to detect your error code with JSFiddle’s JSLint:

Extra comma:

return 

And some unclosed function.
How about this:

// Set up Sliders
// **************
$(function() {
$('#slider1').anythingSlider({
mode: 'f',
resizeContents: false,
navigationSize: 20,
navigationFormatter: function(index, panel) {
return [index - 4];
},
onSlideBegin: function(e, slider) {
// keep the current navigation tab in view
slider.navWindow(slider.targetPage);
},
resumeOnVideoEnd: true,
resumeOnVisible: true,
addWmodeToObject: "opaque",
isVideoPlaying: function(base) {
return false;
}
});
});