function replaceChars(entry,out,add)
{

	temp = "" + entry;
	while (temp.indexOf(out)>-1)
	{
		pos=temp.indexOf(out);
		temp = "" + (temp.substring(0, pos) + add + temp.substring((pos + out.length), temp.length));
	}
	return temp;
}

function isEmailAddress(theElement)
{
	var s = theElement.value;
	var filter=/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3,4})+$/;
	if (s.length == 0 )
		return true;
	if (filter.test(s))
		return true;
	else
		return false;
}


