How to extract product weight from this HTML
- by Blankman
My HTML looks like this:
<td class="main"><b>Product Weight (2.83 lbs in 1 container)</b></td>
I need to get the value 2.83 from the HTML.
Need help with the regex.
I have this:
Pattern p = Pattern.compile(
"<td\\sclass=\"main\"><b>Product\\sWeight\\s\\s((?:\\d+\\.)?\\d+ \\w{3})");
But doesn't seem to be working.
Am I missing an escape or something?