Ich habe eine Website (ungefähr so:)
Code: Alles auswählen
Content = '<b>Anzahl (18087)</b></td>'
Code: Alles auswählen
m = re.compile ( "<b>Anzahl [0-9]*</b>" )
iterator = re.finditer ( m, Anzahl )
for match in iterator:
t = match.span ( )
# print t
Anzahl = Content[t[0]:t[1]-9]
Also was muss ich an Stelle von [0-9]* schreiben, damit nicht "Anzahl 34" sondern "Anzahl (34)" erkannt und ausgelesen wird?
Danke schon mal
Bye, Transmitter
Edit (Leonidas): Code in Python-Tags gesetzt.