String.prototype.trim = function () {
	return this.replace(/^\s*|\s*$/,'');
}
String.prototype.setSpaces = function () {
	this.trim();
	return this.replace(/\s+/g,' ');
}