Site logo

[Support request] Adding Adsense Code

Home Forums Support [Support request] Adding Adsense Code

Home Forums Support Adding Adsense Code

Viewing 15 posts - 1 through 15 (of 15 total)
  • Author
    Posts
  • #2575391
    info@initial.golf

    Hi,

    I’m looking to add adsense code to my site https://initial.golf/ for the first time.

    Google tells me to: “Copy and paste this code in the HTML of your site, between the <head> and </head> tags.

    Your AdSense code:

    <script async src=”https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-2139609159053693&#8243;
    crossorigin=”anonymous”></script>”

    Can someone let me know the best practice for doing this and preferably a step by step guide. I want to show auto ads.

    Many thanks,
    Tom

    #2575438
    David
    Staff
    Customer Support

    Hi there,

    you can add code inside your sites <head> element using a GP Hook element.

    1. Go to Appearance > GeneratePress and activate the Elements module.
    2. In Appearance > Elements -> Add New and choose the hook element

    https://docs.generatepress.com/article/hooks-element-overview/

    3. in the hooks text area, paste your AdSense code.

    4. Set the Hook to: wp_head

    5. Set the Display Rules to: Entire Site

    6. Publish the hook.

    And then its just a case of waiting for Google to validate that code. Which can take a few hours or in some cases a few days. Your adsense console should keep you informed.

    #2575548
    info@initial.golf

    Hi,

    Many thanks, I’ve done this (I think) and have requested a review from google but every time I hit “request Review” within Adsense I get a pop up message to say: “Something went wrong. Please try again later.”

    Do you know why this could be? I’ve tried on a few different devices and get the same message.

    Thanks,
    Tom

    #2575786
    David
    Staff
    Customer Support

    At any time did you try adding the code using any other methods such as a plugin or other function?
    As it will throw those errors if it finds more than one code on the site. And i can see 2 x codes.

    #2575797
    info@initial.golf

    Hi,

    Yes, previously I have added site kit but removed this due to slow page speed.

    Are you able to let me know where I can go in and remove the code that could be forcing the error?

    Thanks,
    Tom

    #2576224
    Fernando
    Customer Support

    Hi Tom,

    To clarify, do you still have the Site Kit plugin or another plugin that could be adding an advertisement?

    If so, try disabling it.

    #2576434
    info@initial.golf

    Hi,

    Site kit plugin has been removed.

    I’m not aware of any other plugins that would be adding advertising.

    I cannot see the code that David speaks of. It is possible to let me know where this is so I can go in and remove it?

    Thanks

    Tom

    #2576674
    David
    Staff
    Customer Support

    Ah… many users who have had SiteKit installed have reported similar problems, where the code that the plugin added is left over after the plugin was uninstalled. And i don’t know what the answer to that is. Can you check with the SiteKit Support ?

    For reference here is that code in the <head> of your site:

    2023-03-22_11-49-56

    #2576694
    info@initial.golf

    Hi,

    Thanks, I’ve put in a community request through Adsense but I’m not sure this is going to work.

    Is there no way of me going in and deleting that code you can see?

    Thanks,
    Tom

    #2576819
    David
    Staff
    Customer Support

    I think you may have to reinstall the plugin and then go through its settings and disconnect from any services.
    And then uninstall the plugin.

    #2576870
    info@initial.golf

    Hi,

    I’ve done this now, I believe the code is no longer showing. Are you able to confirm?

    Thanks,
    Tom

    #2577040
    David
    Staff
    Customer Support

    I can still see that code i provided the screenshot too…
    I am not sure how they inject the code into the <head> it may be by a proxy server so may take a while for that to clear.
    I think you may have to ask SiteKit support for some input

    #2577123
    info@initial.golf

    I have no idea how to get rid of this. I cannot contact Adsense or site kite directly. Is there no way of just going in and removing this code myself?

    Thanks,
    Tom

    #2577193
    Simon

    Hi,
    I stumbled across a post on another forum sometime ago and I think this plugin was used to delete it along with a load of other stuff not needed anymore. Could always drop them a message and ask:

    https://www.gabelivan.com/contact/

    #2577252
    David
    Staff
    Customer Support

    OK. First thing to test is whether that code has been cached.
    Can you disable any cache / optimization plugins. And clear any server caches.
    We can then check if its still there.

Viewing 15 posts - 1 through 15 (of 15 total)
  • You must be logged in to reply to this topic.