Hub Hack: Force Link CTAs to Open in the Same Window

Follow

Use this Custom Code snippet to force Link CTAs to open in the same window, rather than a new window.


 

Details

  • Type: JavaScript
  • Placement: Body Bottom

 

Code

<script>
Hubs.onLoad = Hubs.onPageChange = Hubs.onItemsLoaded = function removeOpenInNewWindow() { $('.cta-button').each(function() { $(this).attr('target', '_parent'); }); }
</script>

 

0 out of 0 found this helpful

Comments

0 comments

Please sign in to leave a comment.