Support » Plugin: Image Refresh » Links

  • Resolved jadams99


    This plugin is great! I’m hoping to turn the image in a link to a custom URL (best would be to use the image’s display settings – custom URL). There’s mention of using the -markup action/filter so maybe just a simple example would get me in the right direction? I think there’s mention of adding a url_link to the shortcode or image attributes in these support forums.

    Some backstory – our site used a Slider which isn’t WCAG compatible so of course audit and I’ve had to ditch that. Yours seems to be the best/easiest random-image-on-load plugin that preserves the alt tag (most galleries don’t), but that the image needs to be clickable (to it’s own page).

    Thanks again for making this plugin available! And great to hear it is still being maintained!

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Micah Wood



    I’m glad to hear you like the plugin!

    If you are wanting an image to link directly to its own post or page, you may want to check out my other plugin Random Post on Refresh. It would be easy to have it display a random featured image from a post and it would automatically link you to the post.

    After installing and activating the plugin, just add this shortcode:
    [random_post_on_refresh show="image"]

    Thanks. Got it working great to display just the post’s image, but that the link takes you to the post (doing exactly what you said it would!), rather than a potentially custom link for the image.

    I see now that the image’s link URL (as in the href surrounding the img src, not the img’s url) isn’t saved anywhere. I’m not as sure about the image element’s “picture link url” but I can’t see a way to have at that either. Clearly at this point it is obvious I’m a bit out of my depth.

    I’m going to attempt to shunt people from the post to a custom url, combining Random Post on Refresh with something else (maybe “page links to” plugin).

    Thank you again for the advice!

    Plugin Author Micah Wood



    Yep, the only problem with trying to use a custom link with the image refresh plugin is that images don’t have the ability to include custom links unless you have setup custom meta data. As that requires coding, I think your plan is probably the simplest.

    • This reply was modified 4 months, 3 weeks ago by Micah Wood.
Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.