Guest Posted February 9, 2017 Share Posted February 9, 2017 (edited) Does anyone know how to do this? I don't need to track a form submission, I need to track individual button clicks. Edited February 9, 2017 by Guest Initial Revision Link to comment
Guest Posted February 10, 2017 Share Posted February 10, 2017 I figured out how to do this! Instead of using a "button" block, use the "custom code" block. Add a link using html where you want the button to go: <a href="/order-now" class="custom-button-black" onClick="ga('send', 'event', { eventCategory: 'order_now', eventAction: 'button_click', eventLabel: 'section_intro'});" >Order Now</a> The link will take uses who click the button to my "order now" pag In "class" we assigned the link the "custom-button-black" class. The third part of the link is the GA tracking code Now we'll create a button in the custom CSS panel for that class. Add this code in the custom CSS panel: .custom-button-black { display:block; margin:auto; width: 25%; height: auto; background-color:black; color: white; text-align: center; vertical-align: middle; line-height: 50px; border-radius: 3px; letter-spacing: 1px; font-family: "proxima-nova"; font-size: 10px; text-transform: uppercase; letter-spacing: .2em; font-weight: 600; font-style: normal; } Link to comment
Guest Posted February 21, 2017 Share Posted February 21, 2017 This tutorial helped me get it right after hours of trying to find a way You need to use Google Tag Manager but its the best way ive found and it works https://answers.squarespace.com/questions/167543/how-to-track-button-clicks-with-google-analytics-e.html Link to comment
conversiontracking Posted November 1, 2018 Share Posted November 1, 2018 (edited) Paid plugin also available If you're frustrated with tutorials and want a quick solution that definitely works, check out Squarespace Click Traking Plugin. It's a paid solution, but a few dollars also makes it 100% sure to work. Money back if it doesn't and 1-on-1 support provided if you have any problems. The Squarespace Button Block is basically a link as any other, so link tracking is what you need. And it's what our plugin does. The plugin tracks outbound links, internal links, file downloads, button links, social media links etc. Edited November 1, 2018 by voxpopagency Initial Revision martinezlorna13 and khayrab 1 1 Freelance Squarespace developer making plugins like Full-Width Blocks, Hover effects for grid gallery and the Darkmode plugin. I know Squarespace inside out and I'm able to solve pretty much any Squarespace code problem. Get in touch here! Link to comment
talmiae Posted July 2, 2019 Share Posted July 2, 2019 Did this work for anyone? I can't get it to work for me :( Link to comment
geekspice Posted April 1, 2020 Share Posted April 1, 2020 This worked for me, thanks for the help. Link to comment
khayrab Posted April 6, 2020 Share Posted April 6, 2020 On 11/1/2018 at 12:29 PM, voxpopagency said: Paid plugin also available If you're frustrated with tutorials and want a quick solution that definitely works, check out Squarespace Click Traking Plugin. It's a paid solution, but a few dollars also makes it 100% sure to work. Money back if it doesn't and 1-on-1 support provided if you have any problems. The Squarespace Button Block is basically a link as any other, so link tracking is what you need. And it's what our plugin does. The plugin tracks outbound links, internal links, file downloads, button links, social media links etc. Unfortunately, the tracking plugin link was broken after I paid. I'm troubleshooting with them. Link to comment
martinezlorna13 Posted April 15, 2020 Share Posted April 15, 2020 On 4/6/2020 at 9:27 AM, khayrab said: Unfortunately, the tracking plugin link was broken after I paid. I'm troubleshooting with them. Were you able to fix it? Im thinking on buying it Link to comment
martinezlorna13 Posted April 15, 2020 Share Posted April 15, 2020 On 4/6/2020 at 9:27 AM, khayrab said: Unfortunately, the tracking plugin link was broken after I paid. I'm troubleshooting with them. Link to comment
martinezlorna13 Posted April 15, 2020 Share Posted April 15, 2020 I used https://codeandtonic.com/products/click-tracking-plugin and it works! conversiontracking 1 Link to comment
conversiontracking Posted April 2, 2021 Share Posted April 2, 2021 (edited) On 4/15/2020 at 6:28 PM, martinezlorna13 said: I used https://codeandtonic.com/products/click-tracking-plugin and it works! Glad to hear it! I'm going to be working on more solutions to this and will try and write more tutorials on this. Not enough info on Squarespace, Google Analytics and Tag Manager (all of which I'm specialized on). Google Tag Manager is perhaps overkill if it's only for few button clicks. But now that new Google Analytics 4 is out, our Click Tracking Plugin doesn't yet support that so GTM is the way to go. Will update the plugin soon. For any custom button/form/link tracking stuff I can also help 1-on-1: hire {ä} codeandtonic.com Edited April 2, 2021 by codeandtonic formatting Freelance Squarespace developer making plugins like Full-Width Blocks, Hover effects for grid gallery and the Darkmode plugin. I know Squarespace inside out and I'm able to solve pretty much any Squarespace code problem. Get in touch here! Link to comment
GregPeterson Posted March 3 Share Posted March 3 On 4/3/2021 at 8:45 AM, codeandtonic said: Glad to hear it! I'm going to be working on more solutions to this and will try and write more tutorials on this. Not enough info on Squarespace, Google Analytics and Tag Manager (all of which I'm specialized on). Google Tag Manager is perhaps overkill if it's only for few button clicks. But now that new Google Analytics 4 is out, our Click Tracking Plugin doesn't yet support that so GTM is the way to go. Will update the plugin soon. For any custom button/form/link tracking stuff I can also help 1-on-1: hire {ä} codeandtonic.com Has this been updated yet please? Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment