I am trying to make sure a custom image links to an external website, the code below works fine but I'm unable to open it in a new window, even tough I'm using target='_blank' in the "a" tag.
<a href="[types field='collaboration-url' output='raw' target='_blank'][/types]">[types field='collaboration-website-image' title='[types field='collaboration-name'][/types]' alt='%%ALT%%' align='left' size='medium' resize='proportional'][/types]</a>
Minesh
Supporter
Languages:
English (English )
Timezone:
Asia/Kolkata (GMT+05:30)
Hello. Thank you for contacting the Toolset support.
I checked the code you shared and I found that you added the target='_blank' attribute within the Types shortcode:
[types field='collaboration-url' output='raw' target='_blank'][/types]
Actually, you need to add the target='_blank' attribute to anchor tag. Please use the following code that will help you to resolve your issue.
<a href="[types field='collaboration-url' output='raw'][/types]" target='_blank'>
[types field='collaboration-website-image' title='[types field='collaboration-name'][/types]' alt='%%ALT%%' align='left' size='medium' resize='proportional'][/types]
</a>
My issue is resolved now. Thank you!