Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #963900

    I want the masonry element not to link to the portfolio page but instead open the portfolio’s featured image in a lightbox.

    I know that in the portfolio entry you can define a custom link with the option Overwrite Portfolio Link setting but do you know a way/function so it automatically links to the featured image in a lightbox?

    #965175

    Hey webcenter,

    Thank you for using Enfold.

    There is another way but you have modify the core or parent theme files which is not recommended. Edit the config-templatebuilder > aviashortcodes > av-helper-masonry.php file, look for this code around line 579.

    if($custom_url)
    					{
    						$this->loop[$key]['url'] = $custom_url;
    					}
    					else
    					{
    						$this->loop[$key]['url'] = wp_get_attachment_image_src($id, apply_filters('avf_avia_builder_masonry_lightbox_img_size','large'));
    						$this->loop[$key]['url'] = reset($this->loop[$key]['url']);
    					}
    

    Replace it with this code.

    $this->loop[$key]['url'] = wp_get_attachment_image_src($id, apply_filters('avf_avia_builder_masonry_lightbox_img_size','large'));
    

    Best regards,
    Ismael

    #970041

    Hi Ismael.
    Thank you for your advice on how to accomplish this, but I will not edit theme core files instead I prefer to find a solution that’s update proof.

    If the portfolio grid would have a ‘load more’ pagination as the masonry element has, I would go with that since the portfolio grid per default links to the image. But the only pagination available for the portfolio grid actually loads the whole page again and so you have to scroll down to the portfolio again and in my case makes it useless because not user friendly.

    #971426

    Hi,

    Unfortunately, it would require quite some time and customization of the theme to achieve this, so I am sorry to tell you that this is not covered by our support. However, if it’s really important for you to get this done, you can always hire a freelancer to do the job for you :)

    Best regards,
    Basilis

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.