This is self-explanatory!

find . -type f -exec sed -i 's/oldstr/newstr/g' {} ;

We used to replace ‘/wp-content/uploads’ with ‘/files’ while merging single wordpress-sites into a big multisite setup.

find . -type f -exec sed -i 's/\/wp-content\/uploads/\/files/g' {} ;

For more details