//This set of function will determine the parameters of the
//user's browser application such as BrowserName, BrowserVersion,
//and ScreenResolution of the users monitor
var useragent = navigator.userAgent;
var bName = (useragent.indexOf('Opera') > -1) ? 'Opera' : navigator.appName;
var pos = useragent.indexOf('MSIE');

if (pos > -1) {
	bVer = useragent.substring(pos + 5);
	var pos = bVer.indexOf(';');
	var bVer = bVer.substring(0,pos);
}

var pos = useragent.indexOf('Opera');

if (pos > -1)	{
	bVer = useragent.substring(pos + 6);
	var pos = bVer.indexOf(' ');
	var bVer = bVer.substring(0, pos);
}

if (bName == "Netscape") {
	var bVer = useragent.substring(8);
	var pos = bVer.indexOf(' ');
	var bVer = bVer.substring(0, pos);
}

if (bName == "Netscape" && parseInt(navigator.appVersion) >= 5) {
	var pos = useragent.lastIndexOf('/');
	var bVer = useragent.substring(pos + 1);
}

//Display the information in hidden tags for submission to other pages
document.write("<INPUT id='BrowserName' name='BrowserName' type='hidden' value='");
document.write(bName)
document.write("'>");

document.write("<INPUT id='BrowserVersion' name='BrowserVersion' type='hidden' value='");
document.write(bVer)
document.write("'>");

document.write("<INPUT id='ScreenResolution' name='ScreenResolution' type='hidden' value='");
document.write(window.screen.width + "x" + window.screen.height);
document.write("'>");
