The re module (cont)Matches
Examples
# Get HTML title
m = re.search("<title>(.*)</title>", s, re.IGNORECASE)
if m:
title = m.group(1)
else:
title = None
Recommended
|
| <<< | O'Reilly OSCON 2000, Introduction to Python, Slide 125 July 17, 2000, beazley@cs.uchicago.edu |
>>> |