// JavaScript Document

// accepts the tr and a highlight color
function highlightRow(row,color) {
	row.style.background=color;
};


function Ltrim(val) {
  var n=0;
  while(val.charCodeAt(n)==160)++n;
  val=val.substr(n);
  val=val.replace(/^\&nbsp;/gi,"");
  val=val.replace(/^\&#160;/gi,"");
  val=val.replace(/^\s*/g,"");
  return val;
};

function isEmail( strValue) {
	var objRegExp  = /^\w+([\-\.]\w+)*\@\w+([\-\.]\w+)*\.[a-z]{2,3}$/i;
	return objRegExp.test(strValue);
}

function getValue(radioGroupName) {
	radios = document.getElementsByName(radioGroupName);
  for (i = 0; i < radios.length; i++) {
  	if (radios[i].checked) return radios[i].value;
  }
};