0

I'm new to Doubleclick for Publishers and wanted to add an HTML5 banner through the service to our website.

After spending days playing with it, I'm now finally able to upload HTML5 banners. The problem is, these don't have any clickTag on them so I had to do it manually.

Adding the tag per se is, of course, trivial (at least, I hope). Now, if I add a target URL, the way it's done on Google's demonstrative example ...

<body>
  <div class="container_dc">
    <a href="javascript:window.open(window.clickTag)">
      <img id="cta_dc">
    </a>    
    <img class="logo_dc"/>
  </div>
</body>

... the banner is un-clickable.

Googling, on the other hand, helped me find this 'solution' ...

<body>   
  <div class="container_dc" onclick="window.open(window.clickTag)">
    <img id="cta_dc">
    <img class="logo_dc"/>   
  </div> 
</body>

... which makes more sense. Sure, now the whole banner is clickable (instead of just the CTA button), but that's not only not a problem, but a much better configuration.

My question is: what method should I use? If I opt of the second one, will DfP be able to 'count' those clicks into the stats?

1 Answer 1

1

In fact the truth is in between:

<body>
  <div class="container_dc">
    <a href="#" onclick="javascript:window.open(window.clickTag)">
      <img id="cta_dc">
    </a>    
    <img class="logo_dc"/>
  </div>
</body>

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.