Hi,
I posted this a couple of days ago and it maybe no one in Support saw it as a pile of others came in after this in a short space of time:
***********************************************************************************************************************************************
Hi,
I have a very simple Gallery where I need the individual images to link to pages on the site.
I have downloaded the WP Gallery Custom Links plugin and that now enables me to add the URLs to the images but they don’t work? For now I have added:
add_filter(‘avf_avia_builder_gallery_image_link’, ‘avia_change_gallery_thumbnail_link’, 10, 4);
function avia_change_gallery_thumbnail_link($link, $attachment, $atts, $meta)
{
$custom_url = get_post_meta($attachment->ID, ‘_gallery_link_url’, true);
if(!empty($custom_url))
{
$link[0] = $custom_url;
$link[‘custom_link_class’] = ‘aviaopeninbrowser’;
}
return $link;
}
to the bottom of Functions.php located in the Enfold theme folder.
I have followed a few threads about this but I haven’t seen anyone confirm that it works.
Any help would be appreciated.
Kind regards,
Brian
Hey brianwelsh!
Ismael replied to your topic here – https://kriesi.at/support/topic/struggling-getting-simple-gallery-images-to-link-to-pages/#post-378135
Best regards,
Yigit