Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

All other Modules /

Discuss all other Modules here.

Moderators: martimiz, Sean, Ed, biapar, Willr, Ingo, swaiba

UserDefinedForm and Google Analytics events


Go to End


4 Posts   1326 Views

Avatar
dave.m

Community Member, 19 Posts

21 July 2015 at 11:40am

I would like to handle the onClick event on form submission to push a GA event - is this possible?

Avatar
Pyromanik

Community Member, 419 Posts

21 July 2015 at 11:35pm

This is a javascript thing, and as such is completely at your discression with having absolute freedom over the rendered output.
So yep, it's possible. I imagine it'll involve something such as https://api.jquery.com/submit/

Avatar
dave.m

Community Member, 19 Posts

21 July 2015 at 11:45pm

Edited: 21/07/2015 11:46pm

Sorry I should have been clearer, this is for the submit action on the UserForms module, not vanilla HTML.

Avatar
Pyromanik

Community Member, 419 Posts

22 July 2015 at 2:13am

The same answer stands ;)