Okay
  Public Ticket #2490583
portfolio external link in new window
Closed

Comments

  •  4
    mkamara started the conversation

    I'm going to add portfolio to my site of all the websites I have built. But I'd like the portfolio Thumbnails to open an external URL in a new Tab/ Window.

    I found some JS code in your support articles you gave to a user in Oct 2018, but this is not working. I suspect because there have been a few updates since then.

    I am using Salient 12. Please let me know if you can help.

    Regards,

    Muenda

  •  2,965
    Andrew replied

    Hello Muenda,

    Please try the following code.

    <script type="text/javascript">
    jQuery( document ).ready(function() {   jQuery('.nectar-post-grid-item a').attr('target', '_blank');
    });
    </script>
    

    Let me know if this works for you.

    Cheers

  •  4
    mkamara replied

    Perfect!! Thank you

  •  4
    mkamara replied

    Hi, Is there also a way to get the post thumbnails to link to an external link in a new tab or window?

  •   Andrew replied privately
  •   mkamara replied privately
  •  2,965
    Andrew replied

    Hi there,

    Please try the following code.

    <script type="text/javascript">
    jQuery( document ).ready(function() {   jQuery('.nectar-post-grid .nectar-post-grid-link').attr('target', '_blank');
    });
    </script>
    

    Let me know if this works for you.

    Thanks.