List of utility methods to do HTML Entities
String | htmlEntites(String str) html Entites return str.replace("<", "<").replace(">", ">"); |
String | htmlEntites(String str) Replaces all opening an closing tags with < or > .
return str.replace("<", "<").replace(">", ">"); |
String | htmlEntities(String s) Escapes special html characters in a string, namely &, <, > and ". s = s.replace("&", "&"); s = s.replace("<", "<"); s = s.replace(">", ">"); s = s.replace("\"", """); return s; |
String | htmlEntities(String text) Converts the ampersand, quote, prime, less-than and greater-than characters to their corresponding HTML entities in the given string. return text.replaceAll("&", "&").replaceAll("\"", """).replaceAll("'", "′") .replaceAll("<", "<").replaceAll(">", ">"); |
String | htmlEntityToString(String dataStr) html Entity To String int start = 0; int end = 0; StringBuffer buffer = new StringBuffer(); while (start > -1) { int system = 10; if (start == 0) { int t = dataStr.indexOf("&#"); if (start != t) ... |