SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Member
    Join Date
    Feb 2001
    Location
    Screw City
    Posts
    15
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Pardon my ignorance...

    How could I go about setting up a form of counter utilizing PHP/mySQL? For example to check link popularity, or tally poll results, etc. I've been looking around for some sort of articles or tutorials, but have only managed to find ones dealing almost exclusively with strings. so any help would be appreciated.

    thanks,
    sod

  2. #2
    SitePoint Addict
    Join Date
    Feb 2001
    Location
    Shanghai, China
    Posts
    214
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Maybe it is not very efficient, but you could set a mysql-query on every site and have a mysql table where you count the pageviews just by using something like this here :

    $times = mysql_query("UPDATE counter SET timesviewed=timesviewed+1 ".
    "WHERE sitename=$sitename");


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •