Reserve space for header ad

Posted in: Newspaper
Post count: 109

Hello!

How can I add some code to reserve space for the header ad slot in order to minimize CLS? I’d like to reserve 250px for the height of the ad slot as explained here: https://developers.google.com/publisher-tag/guides/minimize-layout-shift

Thanks!

Post count: 35449

Hi,
This can be done if you are using banners in two ways:
1. Using the code from the theme panel and just add the extra parameters like style=”min-width: 300px; min-height: 250px;” and the code will be like this https://pastebin.com/MjbHG9x5
2. Use the ad box element https://forum.tagdiv.com/ads-adsense-overview/ -> https://i.imgur.com/LxzmwbU.png
For AdSense code you can use this guide https://support.google.com/adsense/answer/9183363?hl=en
I hope this will help you!
Thank you!

Post count: 2

For Adsense do I need to add code? or will AdSense ride on any empty space on the website?

Post count: 21065

Hello!

Yes, you need to add the code of the ads. Please note that for cloud/PRO templates, you can use the element called “Ad box” from TagDiv Composer and there you need to add the ads code.

Thank you!

Viewing 4 posts - 1 through 4 (of 4 total)
The forum ‘Newspaper’ is closed to new topics and replies.