Ciao a tutti, ho trovato questa funzione per rimuovere qualche tag HTML da una stringa di testo, ma mi sembra un pò riduttiva, considerando che sono un novizio di JAVA sapreste darmi una mano per fare qualcosa di più sensato:
codice:
<%!
String AX_chStr(String theString){
theString = theString.replaceAll("
","");
theString = theString.replaceAll("
","");
theString = theString.replaceAll("","");
theString = theString.replaceAll("","");
theString = theString.replaceAll("","");
theString = theString.replaceAll("","");
theString = theString.replaceAll("","");
theString = theString.replaceAll("","");
theString = theString.replaceAll("","");
theString = theString.replaceAll("","");
theString = theString.replaceAll("<SPAN>","");
theString = theString.replaceAll("<span>","");
theString = theString.replaceAll("</SPAN>","");
theString = theString.replaceAll("</span>","");
theString = theString.replaceAll("<CODE>","");
theString = theString.replaceAll("<code>","");
theString = theString.replaceAll("</CODE>","");
theString = theString.replaceAll("</code>","");
theString = theString.replaceAll("&","&");
return theString;
}
%>