// Browser Detection Script copyright © Cameron T Owen, AKA Dracusis.
// Email cameron@NOSPAM.whatever.net.au

function userIs() 
	{	
	// Inter-Function Pointers	
	d = document; n = navigator	
	a = n.userAgent.toLowerCase()		

	// General	
	this.dom = (d.getElementById)? 1:0	// Document Object Model	
	this.all = (d.all)? 1:0				// Document All (Internet Explorer)	
	this.lyr = (d.layers)? 1:0			// Document Layers (Netscape 4)	
	this.jav = (n.javaEnabled())? 1:0	// Java	
	this.cke = (d.cookie)? 1:0			// Cookies	
	this.img = (d.images)? 1:0			// Images		

	// Specific	
	this.aol	= (a.indexOf('aol')!=-1)? 1:0	// AOL	
	this.op		= (a.indexOf('opera')!=-1)? 1:0 // Opera	
	this.op4	= ((a.indexOf('opera 4')!=-1)||(a.indexOf('opera/4')!=-1))? 1:0			// ^4	
	this.op5	= ((a.indexOf('opera 5')!=-1)||(a.indexOf('opera/5')!=-1))? 1:0			// ^5	
	this.op6	= ((a.indexOf('opera 6')!=-1)||(a.indexOf('opera/6')!=-1))? 1:0			// ^6	
	this.op5up	= (this.op && this.op5 || this.op6 && !this.op3 && !this.op4)? 1:0			// Opera 5 & Up	
	this.op6up	= (this.op && this.op6 && !this.op3 && !this.op4 && !this.op5)				// Opera 6 & Up	
	this.ie		= ((a.indexOf('msie')!=-1) && !this.op)? 1:0								// Internet Explorer	
	this.ie4	= ((a.indexOf('msie 4')!=-1) && this.ie)? 1:0								// ^4	
	this.ie5	= ((a.indexOf('msie 5')!=-1) && this.ie)? 1:0								// ^5	
	this.ie55	= ((a.indexOf('msie 5.5')!=-1) && this.ie)? 1:0								// ^5.5	
	this.ie6	= ((a.indexOf('msie 6')!=-1) && this.ie)? 1:0								// ^6	
	this.ie4up  = (this.ie4 && !this.ie3)? 1:0												// ^4+	
	this.ie5up	= (this.ie5 || this.ie55 || this.ie6 && !this.ie4 && !this.ie3)? 1:0		// ^5+	
	this.ie55up	= (this.ie55 || this.ie6 && !this.ie5 && !this.ie4 && !this.ie3)? 1:0		// ^5.5+	
	this.ie6up	= (this.ie6 && !this.ie55 && !this.ie5 && !this.ie4 && !this.ie3)? 1:0		// ^6+	
	this.ns		= ((a.indexOf('mozilla')!=-1) && !this.aol && !this.op && !this.ie)? 1:0	// Netscape	
	this.ns4	= (this.ns && d.layers && !this.dom)? 1:0									// ^4	
	this.ns6	= (this.ns && this.dom)? 1:0												// ^6 or Mozilla	
	return this
	}