javascript
var v4 = $("#tableContext tbody tr:eq("+i+") td:eq(2)").find("textarea").val().replace(/[\r\n\s]/g,"");
java程序
//去除空格,回车,以及制表符中的空格 String context = ""; Pattern p = Pattern.compile("\\s*|\t|\r|\n"); Matcher m = p.matcher(obj.getString("lcContext")); context = m.replaceAll("");