🛠 Configuration

Here are the integrations that you can configure on the product after installation.

Currently, we only support Adsense ad codes, for more ad networks contact us.

1. Ad code (Adsense) setup

When we create an ad unit from Adsense we get an ad code like below but as we're using Vue.js and Adsense doesn't support it natively so we'll make few changes. Example Ad Code:

// Google Adsense Js script which needs to be run when site load
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js">
</script>
// Element which define our ad unit, need to be placed in respective code
<ins class="adsbygoogle"
style="display:block"
data-ad-client="ca-pub-0000000000000000"
data-ad-slot="0000000000"
data-ad-format="auto" // This ad property needs to be removed
></ins>
// Unnecessary script code
<script>
(adsbygoogle = window.adsbygoogle || []).push({});
</script>

Step 1:

Add JS script of your Adsense code in your Extra code text section. This needs to be done once for all ad units.

<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js">
</script>
Referrence Image

Step 2:

Now copy the <ins> tag element of your ad code and place it in respective ad block.

<ins class="adsbygoogle"
style="display:block"
data-ad-client="ca-pub-0000000000000000"
data-ad-slot="0000000000"
></ins>

Do not forget to remove data-ad-format="auto" property.

Referrence Image

2. Cron job setup

The cron job must be set up as it is responsible for handling background tasks.

  1. Create a new cron job with one of the following commands to run once in an hour.

    • 0 * * * * wget --quiet -O /dev/null https://yourdomain.com/cron.php

    • 0 * * * * wget --spider -O - https://yourdomain.com/cron.php >/dev/null 2>&1

    • 0 * * * * curl --silent https://yourdomain.com/cron.php

  2. Make sure to replace the https://yourdomain.com/ string with your domain name.