Open quartzmo opened 11 years ago
Could always just add event tracking for the subscribe button too, that's what I ended up doing. Be nicer to bind it to the submit event of the form though.
<input type="submit" value="Sign up" onClick="_gaq.push(['_trackEvent', 'Actions', 'Sign up', 'Submitted the signup form']);"/>
Reference: https://developers.google.com/analytics/devguides/collection/gajs/eventTrackerGuide
I just added this in my fork, wasn't sure yet what you had in mind for implementation details so I didn't submit a pull request.
https://github.com/nickhammond/email-landing-page/commit/d86734f79c8c4e62ba5d7ad78417116635f73cee
My implementation idea was to keep things super basic and friendly to any analytics solution by replacing the ajax form with a full page (re)load on submit. The ajax is nice but signing up is such a big event that I'm sure any user will be ok with full reload. (The main goal of this project is to avoid embedding a mailchimp form and going to mailchimp's site for the success/error screen.)
The ajax signup action is nice for the user, but a separate congratulations or thank_you page would make it easier to track signups in analytics software without custom javascript.