Hi,
we need to insert the Tealium inclusion script in a page portion loaded by ajax and i would like to know if there is a way to call the utag.link() after tealium is loaded and ready (so, there is an event that signal this?)
I've tried this:
in ajax page:
(function (a, b, c, d) {
a = '//tags.tiqcdn.com/utag/monclick/qa/ita.desktop/utag.js';
b = document; c = 'script'; d = b.createElement(c); d.src=a; d.type = 'text/java' + c; d.async = true;
a = b.getElementsByTagName(c)[0]; a.parentNode.insertBefore(d, a);
$(document).trigger('mkTealiumLoaded');
})();
and in page (on the page load)
$(document).on('mkTealiumLoaded', function () {
tealiumManager.sendEvent((cartIsOpen ? 'aggiungi step1' : 'apertura step1'), { product_sku: [product.code], product_name: [product.shortDesc.toUpperCase()] });
});
(tealiumManager is our Tealium wrapper)
but, in tealiumManager.sendEvent() the utag object is undefined so i can't send the utag.link()
There is a way to accomplish this?
Thanks for the support
Regards
... View more