explain to me it means the line of code $($menu_items).children(‘a[href!=””]’).click(function() to understand it. thank you
hello d4 when you can let me in writing that means this piece of code $($menu_items).children(‘a[href!=””]’).click(function() , so learn. I have two doubts if it would be okay to add custom html tag id tracking google analytics and if it would be okay to put at the end of dataLayer.push code ({ ‘event’ : ‘ menu- clicks’ or menuitems – click?
in $menu_items you have all those #menu-item.. bla bla bla.
For each #menu-item (which is a li tag) pick up its child link (the a tag) and on the click on this link do function()…
That’s the sense.
About what is better to do with google datalayer I’m afraid, I don’t know anything about that :/
Thank you for explain and help me with the code. I’ll try it on Google Tag Manager with a personalized html tag.
I will tell you how I was.Greetings and thanks d4
Hi d4. I lack the Jquery code send the event to google analytics . Would it be okay if I add var pageTracker = UA- xxxxx , what I have to add code snippet ?