// Check Browser Type
function Is() {
var agent   = navigator.userAgent.toLowerCase();
this.major  = parseInt(navigator.appVersion);
this.minor  = parseFloat(navigator.appVersion);

// Check for NS versions
this.ns     = ((agent.indexOf('mozilla') != -1) && (agent.indexOf('spoofer') == -1) && (agent.indexOf('compatible') == -1) && (agent.indexOf('opera') == -1) && (agent.indexOf('webtv') == -1) && (agent.indexOf('hotjava') == -1));

this.ns2    = (this.ns && (this.major == 2));
this.ns3    = (this.ns && (this.major == 3));
this.ns4    = (this.ns && (this.major == 4));
this.ns4up  = (this.ns && (this.major >= 4));

this.ns6    = (this.ns && (this.major == 5));
this.ns6up  = (this.ns && (this.major >= 5));

this.gecko  = (agent.indexOf('gecko') != -1);
this.ns7up  = this.gecko && (agent.indexOf('netscape/7.')==-1);

// Check for IE versions
this.ie     = ((agent.indexOf("msie") != -1) && (agent.indexOf("opera") == -1));
this.ie3    = (this.ie && (this.major < 4));
this.ie4    = (this.ie && (this.major == 4) && (agent.indexOf("msie 4")!=-1) );
this.ie4up  = (this.ie && (this.major >= 4));

this.ie5    = (this.ie && (this.major == 4) && (agent.indexOf("msie 5.0")!=-1) );
this.ie5_5  = (this.ie && (this.major == 4) && (agent.indexOf("msie 5.5") !=-1));
this.ie5up  = (this.ie && (this.ie5 || this.ie5_5));

this.ie6    = (this.ie && (this.major == 4) && (agent.indexOf("msie 6.")!=-1) );
this.ie6up  = (this.ie && (this.major == 4) && (agent.indexOf("msie 6.")!=-1) );
this.ie7 = (this.ie && (this.major == 4) && (agent.indexOf("msie 7.0") != -1));

// AOL users
this.aol    = (agent.indexOf("aol") != -1);
this.aol3   = (this.aol && this.ie3);
this.aol4   = (this.aol && this.ie4);
this.aol5   = (agent.indexOf("aol 5") != -1);
this.aol6   = (agent.indexOf("aol 6") != -1);
this.aol7   = (agent.indexOf("aol 7") != -1);

//Opera users
this.opera  = (agent.indexOf("opera") != -1);
this.opera2 = (agent.indexOf("opera 2") != -1 || agent.indexOf("opera/2") != -1);
this.opera3 = (agent.indexOf("opera 3") != -1 || agent.indexOf("opera/3") != -1);
this.opera4 = (agent.indexOf("opera 4") != -1 || agent.indexOf("opera/4") != -1);
this.opera5 = (agent.indexOf("opera 5") != -1 || agent.indexOf("opera/5") != -1);
this.opera6 = (agent.indexOf("opera 5") != -1 || agent.indexOf("opera/6") != -1);
this.opera7 = (agent.indexOf("opera 5") != -1 || agent.indexOf("opera/7") != -1);
this.opera8 = (agent.indexOf("opera 5") != -1 || agent.indexOf("opera/8") != -1);
this.opera5up = (this.opera && !this.opera2 && !this.opera3 && !this.opera4);

//Web TV users
this.webtv       = (agent.indexOf("webtv") != -1);
this.TVNavigator = ((agent.indexOf("navio") != -1) || (agent.indexOf("navio_aoltv") != -1));
this.AOLTV       = this.TVNavigator;

//Hot Java users
this.hotjava    = (agent.indexOf("hotjava") != -1);
this.hotjava3   = (this.hotjava && (this.major == 3));
this.hotjava3up = (this.hotjava && (this.major >= 3));

//Mac users
this.mac        = (agent.indexOf("mac")!=-1);

// Hack ie5 js version for mac
if (this.mac && this.ie5up) this.js = 1.4;
this.mac68k  = (this.mac && ((agent.indexOf("68k")!=-1) || (agent.indexOf("68000")!=-1)));
this.macppc  = (this.mac && ((agent.indexOf("ppc")!=-1) || (agent.indexOf("powerpc")!=-1)));

this.macuser = this.mac || this.mac68k || this.macppc;
this.norm    = this.ie4up || this.ie5up || this.ie6up || this.ie7 || this.ns4up || this.ns7up;
this.netscape = this.ns || this.ns4up || this.ns7up;
this.yuk = this.ns || this.ns4up || this.ns7up || this.opera5up || this.opera8;
}

var is = new Is(); // Check Browser Type








