I want to extract this data from a website
You need to add the numbers present in this string. Your string is: 3754537dd2f082ad578e0ff1806d86a6
This is what I was doing
url = opener.open('http://www.website.com') data = url.read() extract = re.search('your string is: <strong>(.*)', data) ans = extract.group(1) ans = string.split(ans, '</strong>') print "Given string "+ans
But it showing me this error.
Traceback (most recent call last): File "time2.py", line 16, in <module> ans = extract.group(1) AttributeError: 'NoneType' object has no attribute 'group'
Which means that
extract has got nothing from website.
How can I solve this problem ? And is there any other/better way to scrape particular data ?