473,796 Members | 2,532 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Are They Lying: $_SERVER["HTTP_REFER ER"] Question

Hi There

A client of mine has some banner ads placed on the net. Instead of relying
on the sites the ads are posted on tell us how many clicks they are
getting, we wanted to track the number ourselves.

I settled on using $_SERVER['HTTP_REFERRER'] to determine what referred the
user to our page. Sure enough, when testing, it all works (ie: i click the
ad on 'sample.com', which takes us to my page, and sure enough in our
tracking database i see 'sample.com' has had the visit count increased by
one.) I am looking for the string "sample.com " to make sure that the count
goes up whether or not the person visited sample.com via
http://www.sample.com or http://sample.com/

My question is: is $_SERVER['HTTP_REFERRER'] reliable? Essentially, a
place my clients have advertised with have said '80 people clicked your ad
this month' while our own stats show that only 15 people clicked it.

Is my method of tracking good/reliable enough to call them liars, or is my
method not too dependable?
Jul 17 '05
14 2682
Rats, you're right. This always gets me...

dictionary.com says:

1 entry found for referer.
<World-Wide Web> A misspelling of "referrer" which somehow made it into the
HTTP standard. A given web page's referer (sic) is the URL of whatever web
page contains the link that the user followed to the current page. Most
browsers pass this information as part of a request.
(1998-10-19)

ECRIA
http://www.ecria.com

"Philip Olson" <ph*********@gm ail.com> wrote in message
news:11******** *************@g 49g2000cwa.goog legroups.com...
BTW it's HTTP_REFERER not HTTP_REFERRER :-)

Jul 17 '05 #11
Good Man (he***@letsgo.c om) wrote:
: Hi There

: A client of mine has some banner ads placed on the net. Instead of relying
: on the sites the ads are posted on tell us how many clicks they are
: getting, we wanted to track the number ourselves.

: I settled on using $_SERVER['HTTP_REFERRER'] to determine what referred the
: user to our page. Sure enough, when testing, it all works (ie: i click the
: ad on 'sample.com', which takes us to my page, and sure enough in our
: tracking database i see 'sample.com' has had the visit count increased by
: one.) I am looking for the string "sample.com " to make sure that the count
: goes up whether or not the person visited sample.com via
: http://www.sample.com or http://sample.com/

: My question is: is $_SERVER['HTTP_REFERRER'] reliable? Essentially, a
: place my clients have advertised with have said '80 people clicked your ad
: this month' while our own stats show that only 15 people clicked it.

: Is my method of tracking good/reliable enough to call them liars, or is my
: method not too dependable?

In addition to what others have said, if the pages are cached anywhere
along the route (gateways and/or proxies) then you won't see all the
traffic.
--

This space not for rent.
Jul 17 '05 #12
Good Man <he***@letsgo.c om> wrote:

} I settled on using $_SERVER['HTTP_REFERRER'] to determine what referred the
} user to our page. ...
}
} My question is: is $_SERVER['HTTP_REFERRER'] reliable? Essentially, a
} place my clients have advertised with have said '80 people clicked your ad
} this month' while our own stats show that only 15 people clicked it.

The short answer, as others have commented, is "no". But the longer answer
is that by and large it *IS* reliable: not very many folk know how to, or
have the facilities to, *change* the REFERER -- there are lots of
filters/firewalls/plugins, etc, that'll _block_ REFERER. so I'd say that
to first order, if you *GET* a REFERER, then it is _most_likely_ correct
[especially if you look for the specific REFERERs that you are expecting]
but you'll be left with the problem of how to sort out hits that come in
with no REFERER.

/Bernie\

--
Bernie Cosell Fantasy Farm Fibers
be****@fantasyf arm.com Pearisburg, VA
--> Too many people, too few sheep <--
Jul 17 '05 #13
A good amount of spanish connections are behind a certain ISP's massive
proxy server too.

It's a long story.

Jul 17 '05 #14
Good Man wrote:
A client of mine has some banner ads placed on the net. Instead of relying
on the sites the ads are posted on tell us how many clicks they are
getting, we wanted to track the number ourselves.


'Clicks', a marketroid's term, isn't it?

--
Jock
Jul 17 '05 #15

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
28688
by: deko | last post by:
I have a page that I don't want anyone to be able to link directly to. The page should only be accessed from gatepage.php. I tried this code, but keep getting errors - "header info already sent", or something like that... Am I missing something, or is there a better way to do this? <?php $ref = $_SERVER; //echo $ref; if ( $ref == 'http://www.mydomain.com/gatepage.php' ) {
2
1760
by: Word Painter | last post by:
this may be more of an "html" issue, but I'll wing it. i've got a multi-language site, where the home-page of each language group features a link to a popup window that offers background info on site management. the popup is fired by a javascript function, when they click the site management link. there's also a "window close" function button so they can nuke it as they please. now, oddly, people who search for my site in the chinese...
10
2308
by: Breana | last post by:
Ok i found this a while back and i am trying to mod it so it works but it keeps not updating the users online and kills my other code? Well i got it working but it dont update when i login? It says 14 guest now, and i am logged in so it sould ream me as member..... And how do i make a cron job, the tutorial says it lowrs site badwith and it runs better updating records?
5
7369
by: Pseudonyme | last post by:
Dear All : Ever had an httpd error_log bigger than the httpd access log ? We are using Linux-Apache-Fedora-Httpd 2006 configuration. The PHP lines code that lead too tons of errors are : $http_ref= $HTTP_REFERER; $prog = $_COOKIE;
2
4312
by: bips2008 | last post by:
The code seems to work fine in other browser but in IE it throws this error. This is very urgent for me and any help would be greatly appreciated For your convienence i have posted the code for the file. The portion that is not working is the star rating part <?php session_start(); include_once('includes/host_conf.php'); include_once('includes/db_connect.php'); include_once('includes/mysql.lib.php');...
0
9679
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10453
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10003
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9050
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7546
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6785
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5441
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5573
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3730
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.