• Hi,
    I would like to have the featured image in my lighbox plugin. To do this, I need to override the featured image url.

    The featured image by default links to the current page, like so:

    <a href="https://www.example.com/this-page-url/" class="post-thumbnail">
    <img src="https://www.example.com/wp-content/uploads/2016/09/imgage-name-default.jpg" class="featured-image">
    </a>

    For lightbox to pick up the image, it needs to link to the image itself. Something like this:

    <a href="https://www.example.com/wp-content/uploads/2016/09/imgage-name-default.jpg" class="post-thumbnail">
    <img src="https://www.example.com/wp-content/uploads/2016/09/imgage-name-default.jpg" class="featured-image">
    </a>

    Any ideas where I apply this override much appreciated.

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘Change default link of featured image’ is closed to new replies.