Black Friday Sale! Get up to $40 off GP Premium!Learn more

[Resolved] Cant add adsense code between the < Head>and tags

Home Forums Support Cant add adsense code between the < Head>and tags

  • This topic has 2 replies, 2 voices, and was last updated 3 years ago by Leo.
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #430207
    Alex

    When i go to Appearance > editor > select theme header (header.php)

    i copy and paste this after the <head>
    <script async src=”//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js”></script>
    <script>
    (adsbygoogle = window.adsbygoogle || []).push({
    google_ad_client: “ca-pub-xxxxxxxxxxx”,
    enable_page_level_ads: true
    });
    </script>

    i get an error and it wont update.

    Unable to communicate back with site to check for fatal errors, so the PHP change was reverted. You will need to upload your PHP file change by some other means, such as by using SFTP.

    GP Premium 1.5.4
    #430213
    Alex

    i added the code into the wp_head hook in GP Hooks

    #430230
    Leo
    Staff
    Customer Support
Viewing 3 posts - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.