Comment on SEO AdSense WordPress Theme by SEO Dave.

AdSense Publisher ID The Stallion Theme Google Google Analytics code is due to be updated for the next release (Stallion 6.3, working on a few new features) to include this AdSense Analytics Code (ASAC) and other improvements (want to include all available Google Analytics code options).

It’s important the code is added above the other Google Analytics and AdSense code so I’ll be adding it in the header.php file, however it doesn’t have to go that high code wise, just as long as it’s above the AdSense and analytics code will be fine.

A short term solution that removes the need to edit template files before the Stallion update is use a Text widget as follows.

Appearance >> Widgets

Add a Text widget to the “Banner Ad Widget” widget area.

In the text widget main form add your code that looks like this:

<script type="text/javascript">
window.google_analytics_uacct = "UA-########-#";
</script>

You don’t have to make any changes to the Stallion Adsense code or the Stallion Google Analytics code, it’s needed as it is. If you aren’t using the Stallion Google Analytics feature and you use a stand alone Analytics plugin check where the plugin adds the code, it has to be below the code above. If a plugin adds the code to the head area the above won’t work (Stallion adds the analytics code to the footer area, so the above works).

When I update Stallion to 6.3 the above code will be built in, so all you’ll have to do is add your Google Analytics code like you do now to the Stallion options page and tick a box to indicate you want the AdSense code adding as well. When you update to Stallion 6.3 delete the text widget with the code above and tick the box :-)

Going to have to stop doing these multiple feature updates and do smaller updates so they are released quicker.

BTW if you do ever add code to the header.php file remember the header2.php file as well. The header2.php file is the header file for the Stallion SEO Super Comments pages, if you have that feature turned on and want some code added sitewide via the header.php file you need to repeat the edit with the header2.php file otherwise your Stallion SEO super Comments pages will lack the code.

David