function String.prototype.Trim() { return this.replace(/(^\s*)|(\s*$)/g, ""); }   
      function String.prototype.Ltrim() { return this.replace(/(^\s*)/g, ""); }
      function String.prototype.Rtrim() { return this.replace(/(\s*$)/g, ""); } 
posted on 2011-05-29 19:33  开心技术  阅读(135)  评论(0编辑  收藏  举报