- TLC Home Home
- Discussions Discussions
- Documentation Documentation
- Knowledge Base Knowledge Base
- Education Education
- Blog Blog
- Support Desk Support Desk
11-01-2017 04:03 AM
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.
Jean-Marc
Solved! Go to Solution.
11-01-2017 07:13 AM
Hi @jmbolfing,
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!
Best,
Kayleigh
11-01-2017 07:37 AM - edited 11-01-2017 07:37 AM
Hey @kayleigh
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.
Cheers...Jean-Marc
11-01-2017 07:47 AM - edited 11-01-2017 07:47 AM
I liked it so I put a kudo on it @kayleigh! #DidYouSeeWhatIDidThere #teehee
11-01-2017 07:50 AM
AAaaahhhh @tamedbeast. Indeed. <sigh>
@kayleigh and @jmbolfing thank you both for your informative replies and answers. Much appreciated. Let us know if you have any other questions!
11-01-2017 08:29 AM
Thanks @kathleen_jo and @tamedbeast!
I saw you marked my answer as the solution, but I don't think that I did actually solve @jmbolfing's problem. Do you all have any insight? I've been trying to do some experimentation in my sandbox, and I can reproduce the issue he's having.
11-02-2017 10:54 AM
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.
11-02-2017 10:59 AM
Nice @steve_lake. Thank you for the reply!
@kayleigh what @steve_lake said! ROFL
11-03-2017 03:16 AM
@jmbolfing @kayleigh @steve_lake
Just to close the loop at bug fix has been raised for this.
Adrian
Copyright All Rights Reserved © 2008-2023