/* Anything Slider custom settings */ $(document).ready(function(){ $('#slider1') .anythingSlider({ // Appearance width : 400, // Override the default CSS width height : 231, // Override the default CSS height resizeContents : true, // If true, solitary images/objects in the panel will expand to fit the viewport // Navigation startPanel : 1, // This sets the initial panel hashTags : true, // Should links change the hashtag in the URL? buildArrows : false, // If true, builds the forwards and backwards buttons buildNavigation : true, // If true, builds a list of anchor links to link to each panel navigationFormatter : null, // Details at the top of the file on this use (advanced use) forwardText : "»", // Link text used to move the slider forward (hidden by CSS, replaced with arrow image) backText : "«", // Link text used to move the slider back (hidden by CSS, replace with arrow image) // Slideshow options autoPlay : true, // This turns off the entire slideshow FUNCTIONALY, not just if it starts running or not startStopped : false, // If autoPlay is on, this can force it to start stopped pauseOnHover : false, // If true & the slideshow is active, the slideshow will pause on hover resumeOnVideoEnd : true, // If true & the slideshow is active & a youtube video is playing, it will pause the autoplay until the video has completed stopAtEnd : false, // If true & the slideshow is active, the slideshow will stop on the last page playRtl : false, // If true, the slideshow will move right-to-left startText : "abspielen", // Start button text stopText : "anhalten", // Stop button text delay : 7000, // How long between slideshow transitions in AutoPlay mode (in milliseconds) animationTime : 600, // How long the slideshow transition takes (in milliseconds) easing : "swing" // Anything other than "linear" or "swing" requires the easing plugin }) .anythingSliderFx({ // '.selector' : [ 'caption', 'distance/size', 'time', 'easing' ] // 'distance/size', 'time' and 'easing' are optional parameters '.caption-top' : [ 'caption-Top', '70px' ], '.caption-right' : [ 'caption-Right', '130px' ], '.caption-bottom' : [ 'caption-Bottom', '70px' ], '.caption-left' : [ 'caption-Left', '130px' ] }) /* add a close button (x) to the caption */ .find('div[class*=caption]') .css({ position: 'absolute' }) .prepend('') .find('.close').click(function(){ var cap = $(this).parent(), ani = { bottom : -50 }; // bottom if (cap.is('.caption-top')) { ani = { top: -50 }; } if (cap.is('.caption-left')) { ani = { left: -150 }; } if (cap.is('.caption-right')) { ani = { right: -150 }; } cap.animate(ani, 375, function(){ cap.hide(); } ); }); });