I
I
It2020-11-23 19:08:14
Search Engine Optimization
It, 2020-11-23 19:08:14

How to track clicks on all menu items?

Tell me how to track clicks on the top navigation on the site. Menu with dropdowns and regular structure in html (li>a).
Used by GTM. The task is to start tracking how users use the menu and understand what is needed in the menu and what is not.

It is clear how to set up a click event on a menu item class, but the question is how to pass the html value from the clicked element to the event label or any other parameter? Like the hrefs value, or even just the name of the link, so that in the end it can somehow be visualized and evaluated.

Sori if the question is banal, but I did not immediately find an obvious solution.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
I
It, 2020-11-24
@IT_Highlander

Everything turned out to be much simpler, you can just use the built-in Click Text variable in the Label tag.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question