External PHP Hits/Month Counter

Discussion in 'PHP' started by escocia1, Jan 31, 2010.

  1. #1
    What would be the best way to implement a simple hits/month counter visible on each individual page? Pages are HTML and we need to call an external URL hosted on a different domain, along the lines of google analytics code that can be pasted into the HTML. Will an include or require be acceptable from a security perspective?
     
    escocia1, Jan 31, 2010 IP
  2. SmallPotatoes

    SmallPotatoes Peon

    Messages:
    1,321
    Likes Received:
    41
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Just implement it as an image and then you don't have to worry about include/require; the browser will do it for you.

    <img src="http://whatever/counter.php?x=1&y=2&z=3">
     
    SmallPotatoes, Jan 31, 2010 IP