- TLC Home Home
- Discussions Discussions
- Documentation Documentation
- Knowledge Base Knowledge Base
- Education Education
- Blog Blog
- Support Desk Support Desk
05-20-2014 12:57 PM - last edited on 11-04-2015 02:03 PM by kathleen_jo
I'm adding a Demandbase retargeting pixel to our site, but it's proving to be more complex than I expected. After digging around, it seems like the likely approach is to add a Tealium Generic tag, set the individual variables and functions up as data sources, and then use the Set Data Value extension. That seems like a lot of work for a few lines of code!
Are there any plans to add Demandbase to the current Tag Marketplace? I was shocked to see they weren't already listed.
05-20-2014 01:03 PM - last edited on 11-04-2015 02:03 PM by kathleen_jo
Rick,
There are plans to add all vendors to the marketplace. :) Given the amount of vendors they are usually implemented based on demand by our clients. There is a ticket logged currently to add Demandbase to the marketplace.
If you attach the code snippet you are trying to implement, we may be able to suggest a method of implementation.
Thanks
05-20-2014 04:11 PM
05-21-2014 10:03 AM - last edited on 11-04-2015 02:04 PM by kathleen_jo
Hey Rick,
This is kind of a tricky one because this code is loading in a JSON file and loading a image request. How I would approach this is taking the following code and pasting it into a Tealium Custom Container Tag Template. On about lines 99-101 of Tealium Custom Container Template you'll see:
/* Start Tag Sending Code */
// Insert your tag sending code here.
/* End Tag Sending Code */
You can simply copy and paste this directly into the template either after the line "//Insert your tag sending code here" or by replacing that line. I've also attached a template for you if needed.
var page = document.location.href;
db_cta = function () {};
if (top != self) {
page = document.referrer;
}
dbApi = document.createElement('script');
dbView = document.createElement('img');
dbRetarget = document.createElement('img');
dbApi.src='//api.demandbase.com/api/v2/ip.json?key=cc85c8e1e8cd95682aade667a12c7f0e&callback=db_cta&page=' + page + '&page_title=' + document.title + '&referrer=' + document.referrer;
dbView.src='//a.company-target.com/pixel?id=1390002856&type=js';
dbRetarget.src='//a.company-target.com/pixel?id=1390002857&type=js';
dbSc = document.getElementsByTagName('script')[0];
dbSc.parentNode.insertBefore(dbApi, dbSc);
dbSc.parentNode.insertBefore(dbView, null);
dbSc.parentNode.insertBefore(dbRetarget, null);
dbView.style.display = 'none';
dbRetarget.style.display = 'none';
05-21-2014 10:06 AM - last edited on 11-04-2015 02:06 PM by kathleen_jo
Actually the custom template didn't render very well on this thread. If you need help pasting this into the template you can refer to this post or reach out to an Account Manager and they'll loop in the correct resource.
https://community.tealiumiq.com/t5/Developers/Tealium-Custom-Container/m-p/1182
Copyright All Rights Reserved © 2008-2023