• Hi!

    When I add a link to an image caption, the link opens in an image popup (which then says “The image could not be loaded”), instead of opening the linked page.

    Example code:
    [caption id="attachment_701" align="alignleft" width="292"]<img class="wp-image-701" src="https://example.net/wp-content/uploads/2016/03/a.jpg" width="292" height="390" /> Bla Blub <a href="https://www.google.com" target="_blank">Google</a>.[/caption]

    Clicking on google, an image popup opens instead of following to google.com.

    Any help is appreciated!

Viewing 5 replies - 1 through 5 (of 5 total)
  • Do you have a live link to where this is happening?

    Thread Starter mikmakmuk

    (@mikmakmuk)

    Yes, here for example.

    How are you inserting the link into your caption? Are you doing it from within the media gallery or after you’ve inserted the image on your WYSIWYG?

    Thread Starter mikmakmuk

    (@mikmakmuk)

    The latter. Once I’ve inserted the image from the media gallery, I’ve edited the caption and added the link. The image in the media gallery does not have a caption.

    Thread Starter mikmakmuk

    (@mikmakmuk)

    But that doesn’t matter, as the produced code is the same, whether I add the caption text to the picture in the media library or edit the caption via the WYSISYG editor once it is inserted.
    The code is the one in the first post.

    I’ve tried to replicate the problem on a new wordpress installation. It doesn’t happen there. The culprit seems to be the theme I use (flatsome). When I deactivate it, everything works as expected.

    Thanks!

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Image caption link to page’ is closed to new replies.