Avada Forums Community Forum can I open the lightbox of a gallery with a link or a shortcode? Reply To: can I open the lightbox of a gallery with a link or a shortcode?

Michael C
Keymaster
Post count: 540

Hi Zanny, that is also possible but you need to add the data-rel into the button additional attributes. If you check the option description it gives some specific changes that need to be made:

Add additional attributes to the anchor tag. Separate attributes with a whitespace and use single quotes on the values, doubles don’t work. If you need to add square brackets, [ ], to your attributes, please use curly brackets, { }, instead. They will be replaced correctly on the frontend. ex: rel=’nofollow’.

So for this example you would need to add in:

data-rel='iLightbox{mygallery}'

Like so http://prntscr.com/jz14iv