/******************************************************************************
** Copyright (c) 2004 : GTI Online Solutions Limited
**
** This software is provided under the terms of a License Agreement and
** may only be used and/or copied in accordance with the terms of such an
** agreement. Neither this software nor any copy thereof may be provided
** or otherwise made available to any other person. No title or ownership
** of this software is hereby TRansferred.
**
*******************************************************************************/
// Tests whether or not Cookies are enabled in the user's browser.
function returnBlnCookiesEnabled(astrSystem) {
	var strCookieName = astrSystem + "_test_cookie";
	var blnCookiesEnabled = false;    // Boolean value to be returned
	
	document.cookie = strCookieName + "=test";    // Create a test Cookie
	
	// Could check for any Cookies, but looking for the test one is the safest option.
	if (document.cookie.indexOf(strCookieName + "=test") != -1) {
		// Cookies enabled, so delete the test one.
		document.cookie = strCookieName + "=delete; expires=Fri, 02-Jan-1970 00:00:00 GMT";
		blnCookiesEnabled = true;
	}
	
	return blnCookiesEnabled;
}

// Tests for support of at least one of the three main DHTML objects.
function returnBlnModernBrowser() {
	var blnModernBrowser = false;    // Boolean value to be returned
	
	if (document.all || document.layers || document.getElementById) blnModernBrowser = true;
	
	return blnModernBrowser;
}
