title: Is there a way in python to replace a string but leave a middle character intact?
body: <p>Is there any way to replace all occurrences of a string in a file, while leaving an unknown character in the middle of the string intact?
  For example, replacing the string 'ab{unknown}cde' with '(ab{unknown}cde)'</p>