You wouldn't be able to use my code as a "link", because $_SERVER runs on the web host itself. Your host machine.

The following is the PHP code I use. You could choose to add or subtract code features. With mine, I send the user IP address to a free GeoIP service, which tries to figure out (geo locate) the Latitude and Longitude, and Country and State. They can be very slow, and with the traffic you have, could just fail, so I am not including it here. Since the info is saved, you can read the file, and process the IP addresses for geo location (Latitude and Longitude, and Country and State) at any time later. You can even manually look up the geo location of an IP address at http://www.infosniper.net/geolocate-...get.php?lang=1

This code saves a file called "ip.txt" on your web server, in the same directory as where the webpage is that you place this code in. (Or you could set a very specific location e.g. www.myDomain/myStats/ip.txt). It is a text file, so you can read it as plain text with any computer script (the results are saved one line at a time, with the data fields comma delimited- think .csv), or viewed with the human eye! You can even copy a handful of lines into a text file on your desktop, and open that new file in Excel, and have it import as csv, fields separated by commas.

I hope I haven't made any typos...

< ? PHP

$FW = date("YmdHis").', '. $_SERVER['PHP_SELF'].', '.$_SERVER["REMOTE_ADDR"].', '.$_SERVER['HTTP_REFERER'].', '.$_SERVER['QUERY_STRING'].', '.$_SERVER['HTTP_USER_AGENT'].PHP_EOL;
$fp = fopen('ip.txt', 'a');
fwrite($fp, $FW);
fclose($fp);

? >



I put the < ? PHP ... ? > in above only to show the start and end of my code example. I put the code in the last module run on each page (footer, copyright, etc).

Example of one line:

20150701002623, /DVD-Detail-TD.php, 46.229.164.99, , id=1126, Mozilla/5.0 (compatible; SemrushBot/0.98~bl; +http://www.semrush.com/bot.html)

Explanation:

20150701002623
Date in UNIX format: 4 characters for the Year, and 2 characters each for the rest MonthDayHourMinSec,

/DVD-Detail-TD.php
The page viewed (your Domain Name would be in front!),

46.229.164.99
The user's IP address,

(in this case, none)
The previous page the viewer viewed,

id=1126
The text following a ? in the URL. http://www.gay-dvds-for-women-and-me...TD.php?id=1126

Mozilla/5.0 (compatible; SemrushBot/0.98~bl; +http://www.semrush.com/bot.html)
The type of web page or web script used to view the page.

^^^^ You can use this info to determine if people are using IE or Chrome or Safari, Android, iOS, MacOS, Windows. For example:
Mozilla/5.0 (iPhone; CPU iPhone OS 7_0 like Mac OS X) AppleWebKit/537.51.1 (KHTML, like Gecko) Version/7.0 Mobile/11A465 Safari/9537.53

Perhaps WordPress gives you this breakdown in its Stats, but you can always capture all of this data yourself and compare. There are additional fields in $_SERVER, but I don't think are of interest. You saw this yourself when you tried it from http://www.porno-mall.com/httpServerTest.php, with the very slow geo location at the bottom.

While all of this goes back 20 years to the origins of the web, this has also been shrouded in mystery- trying to keep us DIY webmasters from knowing too much!


$_SERVER

Array
(
[DOCUMENT_ROOT] => /home/adultmal/public_html/porno-mall.com
[GATEWAY_INTERFACE] => CGI/1.1
[HTTP_ACCEPT] => text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
[HTTP_ACCEPT_ENCODING] => gzip, deflate, sdch
[HTTP_ACCEPT_LANGUAGE] => en-US,en;q=0.8
[HTTP_CONNECTION] => keep-alive
[HTTP_DNT] => 1
[HTTP_HOST] => www.porno-mall.com
[HTTP_REFERER] => http://forums.gaywidewebmasters.com/...rtisment-Space
[HTTP_USER_AGENT] => Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/43.0.2357.130 Safari/537.36
[MAYHEM_DEBUG] => 1
[PATH] => /bin:/usr/bin
[QS_ConnectionId] => 14357739850023905225517
[QUERY_STRING] =>
[REDIRECT_STATUS] => 200
[REMOTE_ADDR] => 98.180.178.76
[REMOTE_PORT] => 35369
[REQUEST_METHOD] => GET
[REQUEST_URI] => /httpServerTest.php
[SCRIPT_FILENAME] =>
[SCRIPT_NAME] => /httpServerTest.php
[SERVER_ADDR] => 185.21.132.44
[SERVER_NAME] => www.porno-mall.com
[SERVER_PORT] => 80
[SERVER_PROTOCOL] => HTTP/1.1
[SERVER_SIGNATURE] =>
[SERVER_SOFTWARE] => Apache
[UNIQUE_ID] => VZQsIbkVhCoAAGOtfZ0AAAHE
[PHP_SELF] => /httpServerTest.php
[REQUEST_TIME_FLOAT] => 1435773985.1215
[REQUEST_TIME] => 1435773985
)


Geolocation information for IP address : 98.180.178.76
Country : United States
Latitude : 38
Longitude : -97