0 Members and 1 Guest are viewing this topic.

*

karloshull

  • *
  • 3
  • osDate Version: osDate v2.5.4
Google ads
« on: March 05, 2019, 04:15:52 PM »
Hi

I cannot get responsive google ads to work on osdate evo 1.3

I have tried putting the ad code in banner_leftside.tpl and the main section goes blank.

Help?

Regards
Karl

*

Pharg

  • *****
  • 3,261
    • OsDateFourm
  • osDate Version: osDateEvo v1.3
Re: Google ads
« Reply #1 on: March 05, 2019, 07:24:52 PM »
Hi Karl,

When you put in a google script in any page, you must add these tags {literal} and closing tag {/literal} so they will work and stops a whitepage error.

Example:
This Normal Google ad would be.
Code: [Select]
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<script>
  (adsbygoogle = window.adsbygoogle || []).push({
    google_ad_client: "ca-pub-00000000000000000",
    enable_page_level_ads: true
  });
</script>

Change the Google ad to this:

Code: [Select]
{literal}
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
<script>
  (adsbygoogle = window.adsbygoogle || []).push({
    google_ad_client: "ca-pub-00000000000000000",
    enable_page_level_ads: true
  });
</script>
{/literal}
Regards,
Pharg ( Phill )

Don't Personal Message me unless it's about a sensitive matter!!

REMEMBER TO ALWAYS BACKUP BEFORE MAKING ANY CHANGES!!

osDateEvo v1.3 | PHP: 5.3.42 & PHP: 7.2 | MySQL: 5.5.35