You can probably use regex Pattern. Here's a little example, though it can be probably made more efficient and abstract:
public static void main(final String[] args) { final String html = "Some text <font> here </font>, and some <font>there</font>"; final Pattern ptrn = Pattern.compile("<font>(.+?)</font>"); final Matcher mtchr = ptrn.matcher(html); while (mtchr.find()) { final String result = html.substring(mtchr.start(), mtchr.end()).replace("<font>", "").replace("</font>", ""); System.out.println(result); } }
Result:
here there
P.S. You probably shouldn't use this for large responses (and I think it's not adviced to use regex for html). Maybe you should use some parser (SAX for one).