(HTML选择性过滤) java正则,过滤掉HTML标签,但保留指定的标签如 a,img,p ( Jakarta ORO实现, perl全兼容正则)
阅读更多packagelix.util;importorg.apache.oro.text.perl.*;classCleanHtml{publicstaticStringclean(Stringhtml){StringBufferbuffer=newStringBuffer();Perl5Utilpreg=newPerl5Util();preg.substitute(buffer,"s/]*?>