All things Shopify and commerce
This is an accepted solution.
Hi @UtopiaCaffe hopes it will help you
To make all buttons on a web page redirect to a new tab when clicked, you can add the target="_blank" attribute to each button's HTML code. This attribute instructs the browser to open the link in a new tab. Here's an example of how you can modify a button's HTML code:
Before modification:
<button onclick="window.location.href='your_destination_url'">Click me</button>
After modification:
<button onclick="window.open('your_destination_url', '_blank')">Click me</button>
In the modified code, window.open is used with the parameters 'your_destination_url' (replace with the actual URL you want to redirect to) and '_blank' (which specifies to open the link in a new tab).
Please note that modifying HTML code might require access to the source code of the website or application. If you're using a Content Management System (CMS) or a website builder, the process may vary. Additionally, be mindful of user experience, as forcing all links to open in new tabs might not be the best practice for usability.
This is an accepted solution.
Hi @UtopiaCaffe hopes it will help you
To make all buttons on a web page redirect to a new tab when clicked, you can add the target="_blank" attribute to each button's HTML code. This attribute instructs the browser to open the link in a new tab. Here's an example of how you can modify a button's HTML code:
Before modification:
<button onclick="window.location.href='your_destination_url'">Click me</button>
After modification:
<button onclick="window.open('your_destination_url', '_blank')">Click me</button>
In the modified code, window.open is used with the parameters 'your_destination_url' (replace with the actual URL you want to redirect to) and '_blank' (which specifies to open the link in a new tab).
Please note that modifying HTML code might require access to the source code of the website or application. If you're using a Content Management System (CMS) or a website builder, the process may vary. Additionally, be mindful of user experience, as forcing all links to open in new tabs might not be the best practice for usability.
Agree with this solution
Thank you so much.
My code doesn't show this line when I find the section for my buttons. Not sure where to go from here.
},
"button_QnC4rP": {
"type": "button",
"disabled": true,
"settings": {
"button_label": "Shop Here",
"button_link": "https://prima-coffee.com/equipment/technivorm/79112-techn-pp",
"button_style_secondary": false
}
}
We recently spoke with Zopi developers @Zopi about how dropshipping businesses can enha...
By JasonH Oct 23, 2024A big shout out to all of the merchants who participated in our AMA with 2H Media: Holi...
By Jacqui Oct 21, 2024We want to take a moment to celebrate the incredible ways you all engage with the Shopi...
By JasonH Oct 15, 2024