Answer the question
In order to leave comments, you need to log in
How to correctly set up an event in Universal Analytics - track form submission?
Good afternoon! The problem is this: there is a website with various feedback forms (ordering a product, sending a resume, asking a question, requesting a demo, etc.), and you need to set up tracking for sending these forms. That is, the visitor came in, filled out a form and sent it. (That is, setting up events in the UA) IMPORTANT: after he clicks "send" he does not see "thank you page", but simply on the same page a message appears like "thank you, your request has been accepted" (the url does not change).
We set it up like this: on the "send" button we hung this
onSubmit="ga('send', Event', 'Order of a specific product', 'Application sent');"
(it is important to track exactly the completed submitted form and not just a click on the button "
(where "ordering a specific product" is the name of the product, respectively)
but events are not counted.
checked, filled out product order forms - does not work.
I suspect that this onSubmit code is configured incorrectly, tell me how to set it up correctly?
Another important point: there is the site.ru site itself and its forms.site.ru subdomain,
all feedback forms are located just on the subdomain. This subdomain was entered into UA as a resource, a UA tracking code was generated for it, the code was added to all pages, in general, everything was done according to the rules - but, nevertheless, events are not counted either in the main domain or in the subdomain.
Answer the question
In order to leave comments, you need to log in
Your task is large-scale, I can’t answer everything, as it takes time.
I would advise you to use Google Tag Manager, which has recently built in the tracking of submitting forms (namely, upon successful submission). I myself have been using it for the last month (it used to be much more difficult with forms).
Here is a very good material on this topic in English: www.simoahava.com/analytics/form-tracking-google-t...
And, yes, you could leave the site URL where you could look at the forms themselves.
Thanks for the answer, here is the site www.gaz-is.ru
and here you can see the forms http://www.gaz-is.ru/klienty/produkty/control-konf...
(there are forms in almost all sections)
GTM we thought about using it, but for now I would like to figure out exactly how to set up UA, and then (when, so to speak, all the basics have already been learned) switch to GTM.
What does your onSubmit look like? Give me the code. Replace ga(...) with alert(1) to see if your code is even running.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question