If your website is based on Wordpress or Blogspot, please check the options above. Otherwise, you can choose from two versions of Anti-Adblock codes: JavaScript and PHP.
If your hosting provider supports PHP, we strongly recommend using the PHP version of the Anti-Adblock code. Otherwise, you'll be forced to update the JS code manually every time new domains get banned by AdBlock.
Integrating JavaScript Anti-Adblock ad channel code
JavaScript code can be used on any host (including free services), but needs to be replaced manually every time after getting our domains in Adblocking software filters (at least once per week).
β
Start Integration by copying the JavaScript code. Copy the code of the tag while creating the tag on the Monetag dashboard.
Paste it into the source code of your website pages right after the <head>
tag.
Do not use Standard and Anti-Adblock code on the same page. The Anti-Adblock code works for all users, whether they have AdBlock enabled or not.
β
Integrating PHP Anti-Adblock ad channel code
Implementing such ad code would require some development skills, but it provides unlimited anti-adblock support for an ad channel without replacing your code.
While creating Onclick Tag, download the PHP file from the Monetag platform containing your Onclick ads code with Anti-AdBlock support.
2. Upload it to your server to the directory where your website's PHP files are located
3. Insert this line below into your .php file where you would normally put an ad serving tag (the best placement for Onclick ads is right after the <head> tag)
echo include_once (dirname(__FILE__) . '/pa_antiadblock_(your zone ID).php');
β
βIf you have any questions, you may contact our Support team via the email address support@monetag.com.