Open in new tab setting from dynamic link

Hi everyone,
I’m building a portfolio website and I need some of the projects in a collection to lead to the project page itself, and some lead to an external page. The issue is that I can’t control whether the ones that lead to the project page will open up in the same tab and the external ones will open up in a new tab. Any ideas who I might be able to do that?

Thanks!


Here is my public share link: LINK
(how to access public share link)

Hello @Uri the best way to do this is to have two fields (external link and internal link) and then each project you fill out the one required. I would recommend to build it this way as well to give you the most flexibility later too, it’ll keep everything cleaner and more future proof

Hi! Sorry for the late reply @Graphic-Logic . I’m not sure I understand how that will open the external link in a new tab, but I found a script that basically make sure that every link that is not on the same domain is opened in a new tab, so I’m good :slight_smile: Thank you!

Hello @Uri glad you were able to solve it! For reference to explain what I meant was just like you have a field for ‘Project Title’ in the CMS, you can add one for ‘Link’ and put any link you want, then link that and make sure it opens in a new tab. Anyway you’ve found your solution that’s great!