/* author: dannwebster@hotmail.com */
/* Generated by AceHTML Freeware http://freeware.acehtml.com */
/* Creation date: 8/21/2003 */

function alertBox(alertMsg)
{
	alert(alertMsg);
}

function confirmBox(confirmMsg)
{
	return confirm(confirmMsg);
}

// Remove all spaces from a string
function removeSpaces(string) {
	var newString = '';
	for (var i = 0; i < string.length; i++) {
		if (string.charAt(i) != ' ') newString += string.charAt(i);
	}
	return newString;
}

/* requires md5.js to be imported into the importing page */	
function verify( attempt, codedAnswer ) 
{
	attempt = trim(attempt);
	attempt = attempt.toUpperCase();
	codedAttempt = hex_md5(attempt);
	return (codedAttempt == codedAnswer )
}

function trim(TRIM_VALUE){


if(TRIM_VALUE.length < 1){
return"";
}
TRIM_VALUE = rTrim(TRIM_VALUE);
TRIM_VALUE = lTrim(TRIM_VALUE);


if(TRIM_VALUE==""){
return "";
}


else{
return TRIM_VALUE;
}
}


function rTrim(VALUE){
var w_space = String.fromCharCode(32);
var v_length = VALUE.length;
var strTemp = "";


	if(v_length < 0){
		return"";
	}
	var iTemp = v_length -1;


    	while(iTemp > -1){
    		if(VALUE.charAt(iTemp) == w_space){}


        		else{
        			strTemp = VALUE.substring(0,iTemp +1);
        			break;
        		}
        		iTemp = iTemp-1;
        	}
        	return strTemp;
    }


function lTrim(VALUE)
{
	var w_space = String.fromCharCode(32);

	if(v_length < 1){
		return"";
	}
	var v_length = VALUE.length;
	var strTemp = "";
	var iTemp = 0;


while(iTemp < v_length)
{
	if(VALUE.charAt(iTemp) == w_space){}
	else
	{
		strTemp = VALUE.substring(iTemp,v_length);
		break;
	}
	iTemp = iTemp + 1;
}
return strTemp;
}