// Function to open a separate window

function TrimStr(str) {
	str = str.replace(/^[ ]+(.*)$/, '$1'); // Trims leading spaces
	str = str.replace(/^(.*)[ ]+$/, '$1'); // Trims trailing spaces
return str;
}

function trim() {
	return this.replace(/^\s*(\S*(\s+\S+)*)\s*$/, "$1");
};
