WordPress.org

Ready to get started?Download WordPress

Forums

Slideshow
[resolved] Slideshow & lightbox? (9 posts)

  1. wzshop
    Member
    Posted 1 year ago #

    Hi there,
    I am using the great slideshow plugin but i was wondering if i could make this slideshow work with a lightbox feature/plugin. I have found some lightbox plugins that automatically create a lightbox URL on each image on my website, but this is not running smoothly with the slideshow plugin:

    - or the lightbox plugin allows me to add an attribute to an <a href>, so i can manually add these <a href> to the slideshow plugin. This enables the lightbox feature for my slideshows, but when i want to go to the next image (within the lightbox) it shows images other than the images added to the slideshow. So it will show more images than ive added to the slideshow.

    - or the lightbox plugin does not provide the feature to manually add an attribute. The lightbox works on all the images but not on the slideshow images.

    Any suggestions to fix this?
    Thanks a lot!
    http://wordpress.org/extend/plugins/slideshow-jquery-image-gallery/

  2. Stefan Boonstra
    Member
    Plugin Author

    Posted 1 year ago #

    Hi,

    A lightbox will be available in version 2.3.0, but a release date has not been set for this version yet.

    Best regards,
    Stefan

  3. jodzeee
    Member
    Posted 1 year ago #

    Yay! That's good news. Any ballpark idea of when? Like in a month, a year, or ??? I'm so excited to use this plugin!

  4. Stefan Boonstra
    Member
    Plugin Author

    Posted 1 year ago #

    I'm hoping I'm not about to kill too much of your excitement, but I'm guessing the lightbox feature will still be a couple of months from now.

    However, you could try to implement a lightbox feature into the slideshow plugin by following the instructions in this thread.

  5. wzshop
    Member
    Posted 1 year ago #

    Fixed it:
    in views/slideshowplugin/slideshow.php

    <?php if (empty($_SESSION['count'])) {
       $_SESSION['count'] = 1;
    } else {
       $_SESSION['count']++;
    } ?>

    In /slideshow.php

    if(isset($_SESSION['count'])):
      unset($_SESSION['count']);
      endif;

    and in views/slideshowplugin/slideshowslide/frontend_attachment:

    if(empty($url))
    			$anchorTagAttributes = 'rel="lightbox[' . $_SESSION['count'] . ']" href="' . $imageSrc . '" ' . (!empty($urlTarget) ? ' target="' . $urlTarget . '" ' : '');

    For more detailed info, leave a response.

  6. leoly
    Member
    Posted 1 year ago #

    can you provide more guidance please, what exactly needs to be changed or are these additions?

  7. wzshop
    Member
    Posted 1 year ago #

    sorry for my late response.
    Jup these are additions.

    in views/slideshowplugin/slideshow.php
    ADD at the top of the file

    In /slideshow.php
    ADD at the bottom of the file

    and in views/slideshowpluginslideshowslide/frontend_attachment:
    ADD at line 51.

    This creates a session id per slideshow, that way the slides can be grouped per slideshow.

    Good luck! Let me know if it worked out!

  8. mahlerthetitan
    Member
    Posted 1 year ago #

    Dear wzshop,
    I created a wordpress.org account just so I could thank you, and say "Bravo!".
    Your suggestions work like a charm. You rock!! :)

  9. wzshop
    Member
    Posted 1 year ago #

    Hey mahlerthetitan,
    Im glad to hear that!
    Cheers!

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic