Jump to content

Would Like For Blogs (used as a directory) to Open in New Tab

Go to solution Solved by tuanphan,

Recommended Posts

  • Replies 3
  • Views 578
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Posted Images

  • 2 weeks later...
  • Solution

(REMEMBER TO SAVE A COPY OF YOUR CURRENT CODE SOMEWHERE, before edit anything)

First, add this code to top of your Universal Filter Plugin code

<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.7.0/jquery.min.js"></script>

image.thumb.png.0192f3d20c181404a906801e26d94b12.png

Next, find this code (bottom of Filter Plugin code)

image.thumb.png.ad041cf03534459b0c0b3b38280dfe16.png

and change it to this

search: {
                enabled: true,// if false, no Search input will be showed
                text: 'Search By Name',
              	searchFunc: 'title',
				}, 
				hooks: {
                onFilter: function(){$('[class*="blog-"] article.blog-item a').attr("target","_blank");},
            }
        }
    }]
};

image.thumb.png.14a5e048c4839984f4529abe6e4813ee.png

Email me if you have need any help (free, of course.). Answer within 24 hours. 
Or send to forum message

Contact Customer Care - Learn CSS - Buy me a coffee (thank you!)

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

×
×
  • Create New...

Squarespace Webinars

Free online sessions where you’ll learn the basics and refine your Squarespace skills.

Hire a Designer

Stand out online with the help of an experienced designer or developer.