If s is a std::string, then is there a function like the following?
s
std::string
s.replace(\"text to replace\", \"new text\");
like some say boost::replace_all
here a dummy example:
#include std::string path("file.gz"); boost::replace_all(path, ".gz", ".zip");