// JavaScript Document

function doFocus(field) {field.focus();}
function trim(sInString) {
  sInString = sInString.replace( /^\s+/g, "" );// strip leading
  return sInString.replace( /\s+$/g, "" );// strip trailing
}
function rTrim(sInString) {
  return sInString.replace( /\s+$/g, "" );// strip trailing
}
function lTrim(sInString) {
  return sInString.replace( /^\s+/g, "" );// strip leading
}

function getThisById(what) {
    if (!document.getElementById) {return}
    elt = eval ("document.getElementById('" + what + "')");
    return elt;
}
function clearInput(input) {
    getThisById(input).value = "";
}

function resizeForm(width,height) {
	if (window.outerWidth) {
		window.outerWidth = width;
		window.outerHeight = height;
	}
	else if (window.resizeTo) {
		window.resizeTo(width,height);
	}
	else {
		alert("Not supported.");
	}
}

