subodh
subodh

Reputation: 6158

Using regex with HTML

I have the string <option value=/digital/collections/newsouth62.html>1862</option> and I want to fetch only the 1862 from the above string using a regular expression.

Upvotes: 2

Views: 84

Answers (1)

fardjad
fardjad

Reputation: 20394

pattern = "|<option.*?>(.*?)</option>|";

Upvotes: 2

Related Questions