WordPress.org

Forums

Lightbox Plus Colorbox
[resolved] Link 1 image to series in lightbox? (3 posts)

  1. bxwebber
    Member
    Posted 1 year ago #

    I'm already using Lightbox Plus on my site linked to a tiled gallery.
    But for another post I'd like to have 1 image that opens up the lightbox to a group of linked images.

    Can this be done using Lightbox Plus Colorbox?

    By the way, I've read the instructions on the developer's site about grouping images, but the sample codes look like Chinese to me.

    https://wordpress.org/plugins/lightbox-plus/

  2. bxwebber
    Member
    Posted 1 year ago #

    Should 've read the last part of the description on the WP-plugin page better - the 'Chinese' I was referring to earlier is clear code here... That gave me one part of the solution. So, in case anyone has the same question, this is the solution:

    1. Put the main image in your post in the usual way (don't forget to link it to the mediafile)

    2. add rel="lightbox[groupID]" to the first part of the a tag ( 'groupID' can be any name you choose for the group of images you want to link).

    3. Add the other images to your post the usual way (again: don't forget to link it to the media file)

    4. Delete the actual <img ..... /> part inside every link of these other images, so you end up with only the a-links (that won't be visible in your post).

    5. Add the same rel="lightbox[groupID]" to every one of these links.

    Et voilá... When you click the image in your post now, the lightbox opens and you can click through the whole group of images.

  3. trizonia
    Member
    Posted 10 months ago #

    Many thanks for this!!!!
    Just a word of caution to those out there who will try this out: Unfortunately WordPress removes empty links, so after writing the image links don't switch to visual mode in your editor, or the links to the images will be lost.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Lightbox Plus Colorbox
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic

Tags

No tags yet.