php: showing google analytics

Posted on 2011-10-11
Last Modified: 2012-05-12
Hello Experts,

I am trying to show basic google analytics information from my clients website in their basic CMS admin section...


Visitors today
Referring Sites

I have had a go at all the tutorials i can find but still cant get a php version to work... can someone a) tell me whether this is possible... and b) give me a very basic example of this

Many Many thanks in advance
from a very frustrated maccaj51

p.s. please be kind... i am not an expert myself
Question by:maccaj51
    LVL 107

    Expert Comment

    by:Ray Paseur
    Why not just go to the Google Analytics pages and see the information right there.  That is how I do it - no need to introduce another level of complexity.
    LVL 5

    Accepted Solution

    If your question is about how to include the google analytics into a PHP based CMS like wordpress, you can use this simple tips from this post:

    Summarily all you need to do is to copy the google analytics to the pages where you want the analytics. You may need to use a file that is common to all your site. E.g the footer.php.  That way any page called from your website (assuming all pages have the footer) will be included in the analytics. Otherwise you might want to copy the analytics into every page.

    This should further give you more insight about it :

    Author Closing Comment

    Thanks for your help!

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    What Should I Do With This Threat Intelligence?

    Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

    Introduction Many web sites contain image galleries; a common design for these galleries includes a page with a collection of thumbnail images.  You can click on each of the thumbnail images to see the larger version of the image.  This is easily i…
    This article will explain how to display the first page of your Microsoft Word documents (e.g. .doc, .docx, etc...) as images in a web page programatically. I have scoured the web on a way to do this unsuccessfully. The goal is to produce something …
    Learn how to match and substitute tagged data using PHP regular expressions. Demonstrated on Windows 7, but also applies to other operating systems. Demonstrated technique applies to PHP (all versions) and Firefox, but very similar techniques will w…
    The viewer will learn how to count occurrences of each item in an array.

    737 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    16 Experts available now in Live!

    Get 1:1 Help Now