• Stop being a LURKER - join our dealer community and get involved. Sign up and start a conversation.

Reply to thread

Yes, but when you're pushing it in the event you can just reference window.modelGA instead of having to parse the URL, etc.


If you wanted to shortcut you could just


[code]

var window.pathDataCombined = "[Item Year] [Item Make] [Item Model]";

[/code]


prepending window just sets it as a variable accessible by the entire current page, so it ignores the scope of functions, etc.

I didn't triple check that GTM can see these variables, but I see no reason why they can't as long as their code executes on the page.