Dec 7, 2008
Pixel Tracker
A Web bug is an invisible 1×1 clear gif that is embedded in a web page or e-mail. These can be used in your emailers to track the actual views of your marketing mailers, capture user data on navigation patterns and high visit areas on your site.
Leave it to your imagination as to what to do with it.
We need the following list of operations in our tracker, for it to be of any use.
We need a appropriate p3p policy.
header("P3P: CP="NOI DSP COR NID ADMa OPTa OUR NOR"");
We need a transparent 1×1 pixel gif image.
//Image header
header("Content-Type: image/gif");
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
header("Cache-Control: no-cache");
header("Cache-Control: post-check=0, pre-check=0");
header("Pragma: no-cache");
//Image Data
$gifData = base64_decode("R0lGODlhAQABAIAAAP///////yH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==") ;
echo $gifData;
When we have cleared this 2 points, we log the data we need.
On this script, we have a day wise table rotator, a new table will be created for every day.
The script is pretty much self descriptive.
So, go ahead and give it a try.
Download the Tracker Script here.
Thanks for info..
keep posting
wow, great post.
I was looking for same and I got it.
thnx a ton.
one suggestion : what about if you give .phps extension to the code so no need to download the zip file. you will save your memory and every one can able to see the code.
Looking for more posts.
Congrags raja. You did it.. Always expecting some good tips from your site…