Most of the popular site usage statistics analyzation software fall flat when attempting to perform some of the more complicated calculations and reporting. Many times we find ourselves wishing we could record and monitor some statistical information, and then not only have it displayed in a useful and meaningfully way, but also in a way that makes sense to us. Specifically my problems with the common webalizer apache log file parser, are its rough-around-the-edges support for referral logs and its handling of google search terms, as well as the complete absence of visually presented trend, or average, lines through time, and the fact that it is imposible to use webalyzer to view real-time information. On the other side there is the javascript based solutions, similar in implementation to "free counters" these setups require extra code be inserted into all of your pages and run on the client side (the number of things that could go wrong with this is a scary thought, given that most of the information can be gathered, safely, on the server-side).
Often, in order to keep track of these traffic statistics a webmaster will use some sort of script or program which monitors visitors and creates reports based on their needs. These scripts can range in size and complexity from a simple hit counter on a page, to a fully integrated data-mining application. They can also range in price from free unsupported scripts, to thousands of dollars for an integrated system. In many cases though, the first option is relatively useless, and the second is unnecessary (and usually outside of the budget). As is true with many things in life, the best solution is usually somewhere in between.
You can get quite a bit of information about your visitors without having to use a third party tracking software. I'll outline the PHP commands you can use to capture some of this data. The details you capture can be saved into a database, and retrieved later to check your site's performance and user details. The following information is captured using the server variable ($_SERVER) which is available from PHP 4.10 onwards.
Joining mailing list will entitle you
to receive occasional emails informing you of news and
updates to the site and any special offers that may be
of interest to you.