Using the script Lightbox2
I would like to place a link (<a>
tag) in the description of the image.
For example:
I would replace "Click the right half of the image to move foward." with Visit My site!
Watch this Image
Using the script Lightbox2
I would like to place a link (<a>
tag) in the description of the image.
For example:
I would replace "Click the right half of the image to move foward." with Visit My site!
Watch this Image
You can add a link in the caption by simply adding the anchor tag in the data-title attribute. For example:
<a href="image.jpg" data-lightbox="example" data-title="Optional <a href='http://google.com'>caption</a>.">My image link</a>
The ability to add anchor tags directly in the data-title attribute without having to encode them first was added in version 2.7.2 on 2015-06-16. Make sure to upgrade if you're using an older version, as this option won't work in older versions of the plugin: