/*
data collection client
version: v1.05
released: 27/06/06
*/


function Statistics()
{
	this.Referer = "" + document.referrer;
	this.Referer = this.Referer.substring(0, 500);
	this.Referer = escape(this.Referer);

	this.Url = "" + document.location;
	this.Url = this.Url.substring(0, 150);
	this.Url = escape(this.Url);

	this.Agent = navigator.appName + ' ' + navigator.appVersion;
	this.Agent = this.Agent.toUpperCase();

	this.ClientCode = "";
	this.Location = "";
	this.MultiLevelTitle = "";
	this.Field1 = "";
	this.Field2 = "";
	this.Field3 = "";
	this.SessionID = "";


	this.MakeRequest = function()
	{

		var sLogUrl = "?r=" + this.Referer + "&u=" + this.Url + "&rnd=" + Math.random();

		if (this.ClientCode != "") sLogUrl += "&cc=" + this.ClientCode;
		if (this.Location != "") sLogUrl += "&l=" + this.Location;
		if (this.MultiLevelTitle != "") sLogUrl += "&mlt=" + this.MultiLevelTitle;
		if (this.Field1 != "") sLogUrl += "&f1=" + this.Field1;
		if (this.Field2 != "") sLogUrl += "&f2=" + this.Field2;
		if (this.Field3 != "") sLogUrl += "&f3=" + this.Field3;
		if (this.SessionID != "") sLogUrl += "&sid=" + this.SessionID;
						
		var p = new Image();

		if( document.location.protocol == "https:" )
		{
			p.src = "https://analytics.fuse8.net/dcc/handler.axd" + sLogUrl;
		}
		else
		{
			p.src = "http://analytics.fuse8.net/dcc/handler.axd" + sLogUrl;
		}
	}
}

