Java tutorial
//package com.java2s; import android.text.TextUtils; public class Main { public static String removeHtml(String htmlStr) { if (TextUtils.isEmpty(htmlStr)) { return ""; } String html = htmlStr; html = html.replaceAll("<(.*?)\\>", " ");//Removes all items in brackets html = html.replaceAll("<(.*?)\\\n", " ");//Must be undeneath html = html.replaceFirst("(.*?)\\>", " ");//Removes any connected item to the last bracket html = html.replaceAll(" ", " "); html = html.replaceAll("&", "&"); html = html.replaceAll("<", "<"); html = html.replaceAll(">", ">"); html = html.replaceAll(" ", " "); return html; } public static boolean isEmpty(String input) { if (input == null || "null".equals(input) || TextUtils.isEmpty(input)) return true; return false; } }