1. Home
  2. Knowledge Base
  3. Modula Basics
  4. Click on an image to open the lightbox using Modula Link shortcode

Click on an image to open the lightbox using Modula Link shortcode

Modula Link is a shortcode that will allow users to create links for their galleries. Normally this shortcode acts as a button to open a lightbox, but you can add an tag inside the shortcode to display an image and then when you click on it it will open the lightbox.

To do this you will need to go to the page where you want to add the image that will open the lightbox, edit it > then using Gutenberg select the shortcode block.

Inside the shortcode block paste this shortcode:

[modula-link id=”GALLERY ID HERE”]<img src=”IMAGE URL HERE”>[/modula-link]

Replace the value for the ID with your Modula gallery’s ID and also replace the src value with the your image’s URL.

You can get the gallery’s ID by going to your dashboard > Modula > Galleries.

And you can get the image’s URL by going to your dashboard > Media Library > hover over the image you need > copy its URL.

Was this article helpful?

Related Articles

Start Building Great WordPress Galleries Now

Fast, Mobile Optimised, and Pixel-Perfect Galleries... What are you waiting for?