> needle = "World" > haystack = "Hello, world!" > replacement = "THERE" > result = haystack.replace(needle, replacement, ignore_case=True) > # result would be "Hello, THERE!"
>>> import re
>>> re.sub('(?i)world','THERE','Hello World')
'Hello THERE'
--
https://mail.python.org/mailman/listinfo/python-list
