﻿var client=new Object();
var other=new Object();
other.sUserAgent = navigator.userAgent;
other.ua=other.sUserAgent.toLowerCase();
client.browser=new Object();
client.browser.Version="0.0";
other.isIE  = false;
other.isFirefox = false;
other.isChrome = false;
other.isOpera = false;
other.isSafari = false;
if (window.ActiveXObject){other.isIE=true;client.browser.Name="Microsoft Internet Explorer";client.browser.Version = other.ua.match(/msie ([\d.]+)/)[1];}
else if (document.getBoxObjectFor){other.isFirefox=true;client.browser.Name="Firefox";client.browser.Version = other.ua.match(/firefox\/([\d.]+)/)[1];}
else if (window.MessageEvent && !document.getBoxObjectFor){other.isChrome=true;client.browser.Name="Chrome";client.browser.Version = other.ua.match(/chrome\/([\d.]+)/)[1];}
else if (window.opera){other.isOpera=true;client.browser.Name="Opera";client.browser.Version = other.ua.match(/opera.([\d.]+)/)[1];}
else if (window.openDatabase){other.isSafari=true;client.browser.Name="Safari";client.browser.Version = other.ua.match(/version\/([\d.]+)/)[1];}
else{client.browser.Version="0.0";client.browser.Name=navigator.appName;}
client.browser.Inf=escape((client.browser.Name+" "+client.browser.Version));
client.agent=new Object();
client.agent.colorDepth=window.screen.colorDepth;
client.agent.Language=(navigator.systemLanguage?navigator.systemLanguage:navigator.language);
client.browser.Url=escape(document.URL);
client.browser.Referrer=escape(document.referrer);
client.agent.screen=screen.width+"*"+screen.height;
other.isWin = (navigator.platform == "Win32") || (navigator.platform == "Windows");
other.isMac = (navigator.platform == "Mac68K") || (navigator.platform == "MacPPC") || (navigator.platform == "Macintosh");
other.isUnix = (navigator.platform == "X11") && !other.isWin && !other.isMac;
if(other.isWin)
{   
    if(other.sUserAgent.indexOf("Windows NT 6.1") > -1 || other.sUserAgent.indexOf("Windows 7") > -1){client.agent.platform="Windows 7";}
    else if(other.sUserAgent.indexOf("Windows NT 6.0")>-1 || other.sUserAgent.indexOf("Windows Vista")>-1){client.agent.platform="Windows Vista";}
    else if(other.sUserAgent.indexOf("Windows NT 5.2") > -1 || other.sUserAgent.indexOf("Windows 2003") > -1){client.agent.platform="Windows 2003";}
    else if(other.sUserAgent.indexOf("Windows NT 5.1") > -1 || other.sUserAgent.indexOf("Windows XP") > -1){client.agent.platform="Windows XP";}
    else if(other.sUserAgent.indexOf("Windows NT 5.0") > -1 || other.sUserAgent.indexOf("Windows 2000") > -1){client.agent.platform="Windows 2000";}
    else if(other.sUserAgent.indexOf("Windows 9x 4.90") > -1 || other.sUserAgent.indexOf("Windows ME") > -1){client.agent.platform="Windows ME";}
    else if(other.sUserAgent.indexOf("Win98") > -1 || other.sUserAgent.indexOf("Windows 98") > -1){client.agent.platform="Windows 98";}
    else if(other.sUserAgent.indexOf("Win95") > -1 || other.sUserAgent.indexOf("Windows 95") > -1){client.agent.platform="Windows 95";}
    else{client.agent.platform="";} 
}
else if(other.isMac)
{ 
    client.agent.platform="Mac";
}
else if(other.isUnix)
{
    client.agent.platform="Unix";
}
else
{
    client.agent.platform="";
}
other=null;
var referrer=client.browser.Referrer;
var url=client.browser.Url;
var browsername=client.browser.Name;
var browserinf=client.browser.Inf;
var color=client.agent.colorDepth;
var platform=client.agent.platform;
var language=client.agent.Language;
var screeninf=client.agent.screen;
client=null;
var url="/inc/site.aspx?Sid=1&Referrer="+referrer+"&Url="+url+"&screen="+screeninf+"&browsername="+browsername+"&browserinf="+browserinf+"&color="+color+"&platform="+platform+"&language="+language;
document.write("<img src=\""+url+"\" border=\"0\" width=\"0\" height=\"0\" />");