I have the following HTML:
<tr><td><font color="#306eff">P: </font>9283-1000<font color="#306eff">
OR (newline)
<tr><td><font color="#306eff">P: </font>9283-1000
<font color="#306eff">
I went to regexpal.com and entered the following regex:
P: </font>(.*?)<font
And it matches. But when I do it in Java, it doesn't match:
Pattern rP = Pattern.compile(">P: </font>(.*?)<font");
Matcher mP = rP.matcher(data);
if (mP.find()) {
System.out.println(mP.group(1).trim());
}
There are multiple regexes I tried on different occasions and they simply don't work in Java. Any suggestions? Thanks!