GA Codes 

GA Codes

At Acumen, we want to add Google Analytics on our WordPress installation, and we want the ability to track our posts and our pages separately using Google Analytics properties. We also want to keep our analytics more accurate by filtering out visits from our team members. To do this, we decided to build a free plugin, Smarter Analytics. Smarter Analytics allows you to:

  1. Apply different tracking codes to posts and pages
  2. Apply tracking codes on a per-post/per-page basis
  3. Filter out IPs from being tracked
  4. Filter out logged-in users from being tracked

GA Codes

When the plugin renders the script, it first makes sure you do not fall in the exclusion rules.

If you do, it comments out the script in HTML so users can see why the script has been commented out and what code would have rendered – this is very useful for testing!

But if the script is to be rendered, it first checks to see if the post has its own code setting.

Then, if it does, it renders. If not, it falls back to the post/page and global defaults.

Download the source code from the WordPress plugin directory and add Google Analytics to your WordPress installations with ease. (We’re using it on this site!)

Have a question about this plugin? Feel free to ask by commenting below.

For information about how Acumen can help with your software design needs, contact us today!