Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Contributor Mottie

    (@mottie)

    Hi CarolineElisa!

    It seems to work for me: https://www.storybox.co.nz/2012/test-project/#video

    Edit: Oh duh, you meant the link on the page. Just add this bit of code:

    jQuery('a[href*="#video"]').click(function(){
        jQuery('.anythingBase').anythingSlider(4);
    });

    It doesn’t use #video because the video extension replaces the id of the video on the iframe. So either target slide 4 or the id or class name of the element wrapping the iframe.

    Thread Starter CarolineElisa

    (@carolineelisa)

    Thanks Mottie!

    I want to make it easy for my client to add these links, so I think it is best to wrap the slide in an element with an id of “video”, rather than use jQuery…

    It now works: https://www.storybox.co.nz/2012/test-project/

    However, after jumping to the video slide, the slideshow then goes to the next slide as normal, but then stays on that slide while cycling through all the thumbs before resuming the slideshow…

    This is a bit unexpected. If it can’t be easily fixed, I would prefer to stop the slideshow after clicking the “#video” link.

    What do you suggest?

    Thanks again,
    Caroline

    Plugin Contributor Mottie

    (@mottie)

    Hmm, well now the link isn’t associated with the slider at all. Maybe the next best solution would be to add the code, but link to the video id instead of a specific slide?

    jQuery('a[href*="#video"]').click(function(){
        jQuery('.anythingBase').anythingSlider( this.hash );
    });

    The reason I didn’t do this in the first place was because of the HTML. Now with the code above, you can make links to multiple videos, all of which will need a wrapper with an id that matches the href:

    <a href="#video1">First video</a>
    <a href="#video-two">Second video</a>
    <a href="#video99">Better than video 98</a>
    Thread Starter CarolineElisa

    (@carolineelisa)

    Hi again Mottie! Sorry to take to so long to reply. This project got put on hold.

    The code is mostly working, just one thing…

    When I click the link and the slideshow is in transition, it still goes to the slide it was going to anyway.

    Any way to override this?

    Here is the page: https://www.storybox.co.nz/wordpress2/2012/after-light

    Thanks!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘[Plugin: AnythingSlider for WordPress] Jumping to a particular slide’ is closed to new replies.