I have several load rules which are not scoped to tags. Instead, they are used in the currency converter extension only.
Here's the problem: If they are not scoped to a tag, they will not be included in the utag.js and thus the currency converter extension conditions will never evaluate to true.
The load rule's conditions are so that they check if country = x and currency = y. Each one for a different country/currency combination. So they are mutually exclusive and I cannot scope all of them to the Currency Converter Tag for example.
Workaround is to have one converter tag for each load rule or create a "ghost" generic tag to which all of the load rules are applied (so it would not load and the load rules will be included in utag.js).
Have I overseen anything or is this the way to follow?
Many thanks in advance for your thoughts.
Solved! Go to Solution.
If I understand your issue correctly, it might be an order of operations issue. Have you checked when this extension loads? Load rules should all be loading to the page, but do so after the data layer evaluates. Extensions can be set to evaluate before or after the load rules. In this case, if you have a variable in the UDO called "country", for example, and the load rule is "if country is Brazil", the currency extension to convert US dollars to Brazil Real relies on that data being available, so the extension would need to evaluate "after load rules".
Let me know if that helps or if I've misunderstood your question!
11-01-2017 07:37 AM - edited 11-01-2017 07:37 AM
Thanks for your input. Yes, I thought the same thing and it took me a while to get to the point where I discovered that the load rules are simply not contained in the utag.js (in the "utag.loader.loadrules" part of the script). They're just not there. Even if they are active. But once they are scoped to a tag, they are.
11-01-2017 07:47 AM - edited 11-01-2017 07:47 AM
AAaaahhhh @tamedbeast. Indeed. <sigh>
It's true - to optimise the code, if a load rule is not scoped to a tag, the code isn't generated as part of utag.js as (in theory) it's not being used.
In practice, of course, people reference load rules in extensions.
There are two ways around this. The easiest is to create a 'dummy' tag using the Tealium Custom Container tag, and simply don't customise it - it's basically left as a blank template that doesn't do anything, but if you scope it to the load rule, it will legitimise the load rule and make the publishing system build the code.
The other way is to reproduce the load rule as part of the extension - many extensions can use conditions which you can set to reproduce the criteria of the load rule. This is arguably neater, although possibly not so obvious.