我正在尝试将.roll添加到我的nextjs应用程序中。我使用了带有dangerouslysetinnerhtml的script标签,但它无法验证。我在这里错过了什么?
这是密码
<Script`
{
adroll_adv_id = "xxxxxxxxxxxxxxxxxxxx";
adroll_pix_id = "xxxxxxxxxxxxxxxxxxxx";
adroll_version = "2.0";
(function(w, d, e, o, a) {
w.__adroll_loaded = true;
w.adroll = w.adroll || [];
w.adroll.f = [ 'setProperties', 'identify', 'track' ];
var roundtripUrl = "https://s.adroll.com/j/" + adroll_adv_id
+ "/roundtrip.js";
for (a = 0; a < w.adroll.f.length; a++) {
w.adroll[w.adroll.f[a]] = w.adroll[w.adroll.f[a]] || (function(n) {
return function() {
w.adroll.push([ n, arguments ])
}
})(w.adroll.f[a])
}
e = d.createElement('script');
o = d.getElementsByTagName('script')[0];
e.async = 1;
e.src = roundtripUrl;
o.parentNode.insertBefore(e, o);
})(window, document);
adroll.track("pageView");
}`
/>
2条答案
按热度按时间dojqjjoe1#
试试这个代码它对我有用
kognpnkq2#
你可以试试这个,它可能对你有用。