偶尔清空巨大的标签

Empty vast tag occasionally

为什么浩瀚的标签偶尔会变空?我正在用这里的例子进行测试:https://developers.google.com/interactive-media-ads/docs/sdks/html5/client-side/tags#single-vpaid-2.0-linear

我可以随便挑link,例如:

https://pubads.g.doubleclick.net/gampad/ads?sz=640x480&iu=/124319096/external/single_ad_samples&ciu_szs=300x250&impl=s&gdfp_req=1&env=vp&output=vast&unviewed_position_start=1&cust_params=deployment%3Ddevsite%26sample_ct%3Dredirectlinear&correlator=

当我在浏览器中打开它并偶尔重新加载它时 url,我只在大量标签中看到它:(而不是完整的大量文档)

<VAST xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="vast.xsd" version="3.0"/>

这是怎么回事?

您需要确保对 VAST 代码的每个请求都包含不同的相关因子,例如:

https://pubads.g.doubleclick.net/gampad/ads?sz=640x480&...&correlator=4345645667

您可以轻松创建相关随机数生成器作为变量:

var randNum = Math.floor(Math.random() * (9999999 - 1 + 1)).toString();
var vastUrl = "https://pubads...&correlator="+ randomCorrelator;

有关所需参数的完整文档,请参阅 here