Tracking Unique Clicks


Posted on 16th Feb 2014 07:03 pm by admin

Hi guys and gals,

Basically I have a database which tracks clicks on my outbound links, I do this by linking to a page like so...

/redirect.php?id=1

The page then reads the id and increments the click column in the database before selecting the link and redirecting.

I need it to only count the click if its from a unique IP for the link, what would be the best way to do this?

I was thinking of having another table with columns "IP" and "link_id", Then I could check the IP against the list of IP's for the current link. If its not there then add it and add the click, otherwise only redirect.

I want to find the best method before I start to try and code this so any help is appreciated.

No comments posted yet

Your Answer:

Login to answer
91 Like 24 Dislike
Previous forums Next forums
Other forums

How to get the previous months last date....
Here's my wittle problem. I suck at working with dates.

So today is 10/20/2009, i need to fig

Keep newlines from textarea?..
I'm creating a simple encoding program, and what I want it to do is retain the newlines, as echoing

php unable to sent email
Hi, guys, I try to send a email through php but unfortunately the mail unable to sent. Here is my co

Trigger tag in aspx is not coming
hi all ,iam new to ajax, iam using file upload inside the update pannel but right now i want to use

Dynamic links in an include file
I am working on a small piece of code that counts records from a database and displays the result to

adding 0 to numbers
Hey guys i need to create a 00001 number in a loop. Is there a better way of forcing a 5 digit numbe

Run function every 5 mins ??
I have a function PostMessage()

How can I run it every 5 mins ??

Stuck with preg_replace
Hi,

I'm trying to use preg_replace to remove part of the IP address submitted using a form on

PHP/Database issue
My friend is helping me make a database where you go to a certain webpage of my site and the page wi

DOMDocument parsing
Hello, I am parsing an xml file from an API which I have converted into a DOMDocument in php. This i

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash