	String.prototype.trim = function() {	   return this.replace(/^\s+|\s+$/g,"");	}		String.prototype.ltrim = function() {	   return this.replace(/^\s+/g,"");	}		String.prototype.rtrim = function() {	   return this.replace(/\s+$/g,"");	}		String.prototype.toTF = function() {		return this.match(/(^(t|m|on|y|1))/i);	}		String.prototype.tf = function(TTxt,FTxt) {		return this.toTF() ? TTxt : FTxt;	}		String.lDefaultSeparator = function() {		return ",";	}		String.prototype.lSplit = function(sep) {		if (sep == null) sep = String.lDefaultSeparator()		var llist = new Array();		if (this != "") {			var temp = sep + this			for (var pos = temp.indexOf(sep,0); pos >= 0 ; pos = temp.indexOf(sep,pos+1)) {				var endpos = temp.indexOf(sep,pos+1);				if (endpos < 0) endpos = temp.length;				llist[llist.length] = temp.substring(pos+sep.length,endpos);			}		}		return llist;	}		String.prototype.lCount = function(sep) {		if (sep == null) sep = String.lDefaultSeparator();		return this.lSplit(sep).length;	}         	String.prototype.lGet = function(item,sep) {		if (sep == null) sep = String.lDefaultSeparator();		var llist = this.lSplit(sep);		if ((item >= 0) && (item < llist.length)) {			return llist[item];		} else {			return "";		}	}         	String.prototype.lGets = function(start,end,sep,llist) {		var result;		if (sep == null) sep = String.lDefaultSeparator();		if (llist ==  null) llist = this.lSplit(sep);		if (start == null) start = 0;		if (start < llist.length) {			result = llist[start];			if ((end == null) || (end >= llist.length)) end = llist.length -1			for (i=start+1;i<=end;i++) {				result += sep + llist[i];			}		}		return result;	}         	String.prototype.lLast = function(number,sep) {		if (sep == null) sep = String.lDefaultSeparator();		var llist = this.lSplit(sep);		if (number == null) number = 1;		var from = llist.length - 1 - (number - 1);		return this.lGets(from,null,sep,llist);	}         	String.prototype.lRest = function(number,sep) {		if (sep == null) sep = String.lDefaultSeparator();		var llist = this.lSplit(sep);		if (number == null) number = 1;		var from = number;		return this.lGets(from,null,sep,llist);	}       String.prototype.stem = function(sep) {            if (sep == null) sep = String.lDefaultSeparator();            var llist = this.lSplit(sep);            var to = llist.length - 2;            return this.lGets(0,to,sep,llist);        }               String.prototype.leaf = function(sep) {            if (sep == null) sep = String.lDefaultSeparator();            var llist = this.lSplit(sep);            var from = llist.length - 1;            return this.lGets(from,null,sep,llist);        }          	String.prototype.lFind = function(what,sep) {		if (sep == null) sep = String.lDefaultSeparator();		var llist = this.lSplit(sep);		for (var i = 0; i < llist.length; i++) {			if (llist[i] == what) {				return i			}		}		return -1;			}		String.prototype.lSet = function(item,what,sep,llist) {		if (sep == null) sep = String.lDefaultSeparator();		if (llist == null) llist = this.lSplit(sep);		llist[item] = what;		var result = this.lGets(null,null,sep,llist);		return result;	}		String.prototype.lSets = function(start,end,what,sep) {		if (sep == null) sep = String.lDefaultSeparator();		var llist = this.lSplit(sep);		this.lSet(start,what,sep,llist);		if (end > start) llist.splice(start+1,end-start);		var result = this.lGets(null,null,sep,llist);		return result;	}	        String.prototype.lDelete = function(item,sep) {            if (sep == null) sep = String.lDefaultSeparator();            var llist = this.lSplit(sep);            llist.splice(item,1)            return llist.join(sep);        }