Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #498013

    Hi
    I have been trying to make the images in the gallery lightbox display a bit lager. By changing the Max width and height in Media Settings and using this added to the function.php file, from a previous thread, I could do it with the masonry gallery:

    add_filter( ‘avf_avia_builder_masonry_lightbox_img_size’, ‘enfold_customization_change_popup_size’ );
    function enfold_customization_change_popup_size( $size ) {
    return ‘fullsize’;
    }

    But I can’t work out how to change it for the normal gallery.
    You can see the difference here in the page link provided.

    The two galleries are using the same images (1200px width)

    #498542

    Hi envapk2!

    Add this to your functions.php file.

    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)
    {
        $link = wp_get_attachment_image_src($attachment->ID, "full");
        return $link;
    }

    Regards,
    Elliott

    #499160

    Hi Elliott

    That works perfectly
    many thanks

    Peter

Viewing 3 posts - 1 through 3 (of 3 total)
  • The topic ‘Gallery lightbox image size’ is closed to new replies.