Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #1009889

    Hi there,
    I wanted to know if it’s possible that the title link of the Blog Post element are open in a new tab instead of the same tab. Private content:

    #1010212

    Hey inaudit,
    Try adding this code to the end of your functions.php file in Appearance > Editor:

    function open_news_new_tab(){
      ?>
      <script>
      (function($){
      $(document).ready(function(){
      $('h3.slide-entry-title.entry-title a').click(function(){
        window.open(this.href);
        return false;
      });
      });
      })(jQuery);
      </script>
      <?php
      }
    add_action('wp_footer', 'open_news_new_tab');

    I believe this will only effect the links you wish, but please test and let us know if you find any links opening in a new tab that you don’t wish to.

    Best regards,
    Mike

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.