去除网页中的javascript 代码和 多余的 div的方法

/ 2013-09-12
public static String htmlspecialchars(String str) {
		// str = str.replaceAll("&", "&");
		// str = str.replaceAll("<", "&lt;");
		// str = str.replaceAll(">", "&gt;");
		 str = str.replaceAll("<div(.*)|(.*)(\n*)</div>", "");
		 str = str.replaceAll("<script(.*)|(.*)(\n*)</script>", "");
		return str;
	}

Reproduced please indicate the author and the source, and error a link to this page.
text link: //xiaochun.zrlog.com/104.html