// JavaScript Document

// Removes leading whitespaces
function LTrim( value ) {
	
	var re = /\s*((\S+\s*)*)/;
	return value.replace(re, "$1");
	
}

// Removes ending whitespaces
function RTrim( value ) {
	
	var re = /((\s*\S+)*)\s*/;
	return value.replace(re, "$1");
	
}

// Removes leading and ending whitespaces
function trim( value ) {
	
	return LTrim(RTrim(value));
	
}


function makeActivTab(currTabId,currImgUrl)
{
	var defaultImgDir = "images/"
	//alert(linkState);
	var activTabObj = document.getElementById(currTabId);
	activTabObj.src = defaultImgDir+currImgUrl;
}