Hi Guys,

I'd like remove contents between tags <email> that matches pattern "WORD1" as follows:

Change
"stuff <email>[email protected]</email> more stuff <email>[email protected]</email> still more stuff <email>[email protected]</email> stuff after WORD2 <email>[email protected]</email>"

To
"stuff more stuff still more stuff <email>[email protected]</email> stuff after WORD2 "

The following did not work
newl = re.sub (r'<email>WORD1-.*</email>',"",line)

Thanks in advance!
_______________________________________________
Tutor maillist  -  [email protected]
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor

Reply via email to