Jump to content

Can I force all mailto links to open in a new browser window?

Recommended Posts

  • Replies 5
  • Views 2.6k
  • Created
  • Last Reply

Yes you can there are 2 ways to do this :

 

1 - Create a custom link with Code block and use the following code

<a href="mailto:email@gmail.com" target="_blank" >Text you want to show </a>

2 - Code custom Js which is bit complex , Please do let me know if it works with the first one if not will post the 2nd one 🙂 

Link to comment

Ok, thanks for taking the time to answer this and perhaps it will be useful to someone else.

Since this is a client site, and they will be editing their own text from here on out, and the links appear repeatedly within paragraphs throughout the site, I don't want to set them up with all of that text in a markdown block.

 

 

Link to comment

Hi Tuanphan -

I am going to set it up with a Business Plan but it has not been set up yet - it's still in trial mode.

I've got to be honest that I am quite comfortable adding css and html because I understand how it works. Adding js makes me a little nervous! It's not going to cause any problems, is it?

Link to comment
On 10/21/2020 at 9:03 PM, cherylr said:

Hi Tuanphan -

I am going to set it up with a Business Plan but it has not been set up yet - it's still in trial mode.

I've got to be honest that I am quite comfortable adding css and html because I understand how it works. Adding js makes me a little nervous! It's not going to cause any problems, is it?

Js partly affects speed. If you are worried, you can find another way.

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

Archived

This topic is now archived and is closed to further replies.

×
×
  • 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.