Warning: preg_replace(): Compilation failed: invalid range in character class at offset 4 in /home/oly/public_html/getgeek.net/wp-content/plugins/crayon-syntax-highlighter/crayon_langs.class.php on line 340
How to put Adsense Page Level Ads on Wordpress - GetGeek.net

I recently updated some of my adverts on this page and decided to have a play around with putting page level ads on WordPress. If you dont know what these are then they are adverts specific to your mobile page and will only display when they are most valuable to your users. As more people around the world are using mobiles to view the web i thought i would write this article.

There are currently 2 types, an anchor version which will sit at the bottom of your page and will load after your web page therefore it will not interrupt the user experience and the second type which is a vignette type that shows a full screen ad when clicking between pages. Again this will not interrupt the loading of site content and if the user clicks close then the web page is already preloaded behind it. You can choose to switch on either or both in your AdSense settings.

This will require you to edit code so please back up your site before doing so incase you mess something up. I will not take any responsibility if you do. There is also the chance that updating your theme will overwrite this so you may have to do repeat this process if you update.

How to put Adsense page level ads on WordPress

  1. Login to your wordpress page.
  2. Go to “Appearance” in the side bar and then “Editor”.
  3. Click on “Theme Header (header.php)”
  4. Place the code anywhere between the <head> tags. It is probably easier to look for the closing </head> tag and paste it before this as i have done in the image below.

    page level ads on wordpress

    page level ads on wordpress

  5. Save the file by clicking “Update File.”

How to test your page level ads on WordPress

  1. Using a mobile device, browse to your web site and append “/#googleads” to the end. For example if i was testing my page i would browse to “http://getgeek.net/#googleads
  2. You should see the anchor ad first and if you click vignette you should see this when clicking between pages.

Hopefully this guide has helped you out. As mentioned earlier please backup your site before editing the code and i do not take any responsibility if you mess up your site. Happy Coding!

Comments

comments

Subscribe To Our Newsletter and get our Ultimate Web Design Resource list for free!

You have Successfully Subscribed!

Subscribe To Our Newsletter and get our Ultimate Web Design Resource List for free! Whether your starting a blog or your a pro web designer, its FULL of useful resources !

Subscribe To Our Newsletter and get our Ultimate Web Design Resource List for free! Whether your starting a blog or your a pro web designer, its FULL of useful resources !

You have successfully subscribed! Confirm your email address for the free resource list!

Pin It on Pinterest

Share This