Hey there,
I try to migrate completely to the Tag Manager, which is a quiet good Module of matomo (thank’s to the devs).
So I have a Popup on my Website. Not all users got that shown. I want to know two events:
- Popup shows up
- Popup fades out
I quickly got the first one running, but the second one is more tricky. The popup can close via multiple ways (click on an X-Icon, click on the background OR press ESC).
So I had a look on HTML and the popup get’s an special class after fading out. So I created a Variable
function () { return jQuery(".ulp-overlay.ulp-animated.ulp-fadeOut").length; }
So now I need an Trigger which can fire if this variable bigger than 0 or is equal or bigger than 1.
I used a Timer here (seems the best solution for me right now) and set an Condition: “myVariable is equal or bigger than 1” (translated from german).
And here’s the surprise: It doesn’t work.
I debugged that with the mtmPreviewMode.
- In this timer, the variable is 0 as long as I did not close this popup
- In the Variablestab on that event (first timer after popup close) I see, that the Variable is now 1
- In the Triggers tab on that event (first timer after popup close), that no trigger was executed
- In the Tags tab of that event (first timer after popup close) I see, that no tag was executed
I hope I did provide enough information for someone who knows the Tag manager better than me
At the moment my container just has 8 tags, 11 triggers, 3 variables and 11 versions, so I think this is quiet small. But actually there is some logic left in the source code which I want to migrate this week.
Thanks for any feedback.