Something
public text v1 · immutableclass Explosm(Comic):
def __init__(self):
Comic.__init__(self, 'Cyanide and Happiness')
def getImageURL(self):
feed = urllib.urlopen("http://www.explosm.net/comic/")
match = re.search('src=(?P<quote>[\'"])(?P<image>http://www.explosm.net/db/files/Comics/.*\.png)(?P=quote)', feed.read() )
try:
return match.group('image')
except IndexError:
return None