The Grid single image open in new tab

Have you portfolio through The Grid? Can't open a single image in a new tab if the portfolio is done through The Grid? Then we have brought a breakthrough solution for you. Copy the code below and paste it anywhere on your website. Which you can do using any JavaScript code writing plugin.

The javascript code is:

							
							
					<script>
  document.addEventListener('DOMContentLoaded', function() {
    var links = document.getElementsByClassName('tg-item-link');

    for (var i = 0; i < links.length; i++) {
      links[i].setAttribute('target', '_blank');
    }
  });
</script>				
			

The instructions on how to use where are shown in the image below:

developerrazu

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top