Site is Under Maintenance
Please come back again in...
00 Days
00 Hours
00 Minutes
00 Seconds
Wellcome To My Blog Dulpan Adi Saragih. Thanks For Visiting My Blog New! Join Disscusion Now!

How to use Lazyload Adsense?

The posts are updated based on the Latest Template, please follow the steps if you are using version 2.6.1

Lazyload Adsense Scripts
Lazyload Adsense Scripts

Lazyload Adsense helps to improve your Site Performence and its loading time. If you want to lazyload your adsense scripts, here are few steps you have to follow.

You should not use lazyload adsense, while it is under review, you must add the adsense scripts in head section at that time. It is recommended to use lazyload adsense when Adsense has approved your domain, and Ads are ready to show on your domain.

* Follow the steps while your site is under review:

Find the following codes:

<!--[ Defer Adsense script use shinsenter/defer.js ]-->
<!--<script type='deferjs' src='https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-0000000000000000' crossorigin='anonymous'/>-->

Uncomment the codes and replace the marked parts with your Publisher ID. It will look like:

<!--[ Defer Adsense script use shinsenter/defer.js ]-->
<script type='deferjs' src='https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-0123456789012345' crossorigin='anonymous'/>

Using Lazyload Adsense

* Follow these simple steps to use Lazyload Adsense:

Find the following codes:

adsenseAds: {
publisherId: caPubAdsense.replace('ca-pub-',''), /* Auto or replace with Publisher ID i.e. "000000000000", */
antiAdBClose: "true", /* "true", if you want to add a Close Button in Anti Ad Block popup */
ignoreMaxAge: "86400",
loadType: "defer" /* lazy, defer, scroll */
}

If your blog is connected with your Adsense, then no need to replace the marked caPubAdsense.replace('ca-pub-','') otherwise you have to replace it with your Adsense Publisher ID. For eg. replace caPubAdsense.replace('ca-pub-','') with 0123456789012345.

Set the script loading type. For eg. lazy, defer or scroll.

While adding Ad Units, add the marked parts only:

<script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-0123456789012345"
crossorigin="anonymous">
</script>
<ins class="adsbygoogle"
style="display:inline-block;width:728px;height:90px"
data-ad-client="ca-pub-0123456789012345"
data-ad-slot="7060116223"></ins>

<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>

Rate this article

Getting Info...

About Post Author

Cookies Consent

This website uses cookies to ensure you get the best experience on our website.

Cookies Policy

We employ the use of cookies. By accessing Plus UI, you agreed to use cookies in agreement with the Plus UI's Privacy Policy.

Most interactive websites use cookies to let us retrieve the user’s details for each visit. Cookies are used by our website to enable the functionality of certain areas to make it easier for people visiting our website. Some of our affiliate/advertising partners may also use cookies.