除去html空格成一行 .net

 

string tmp=///吧文件读出成string的
 Regex regReplaceBlank = new Regex(">(\\s+)<", RegexOptions.IgnoreCase);
        Regex regReplaceLine 
= new Regex("\\s\\n", RegexOptions.IgnoreCase);
        tmp 
= regReplaceBlank.Replace(regReplaceLine.Replace(tmp, ""), "><");

 

 

posted @ 2010-07-14 11:19  王大湿  阅读(437)  评论(0编辑  收藏  举报