View Single Post
Old 02-14-2017, 06:59 AM  
Barry-xlovecam
It's 42
 
Industry Role:
Join Date: Jun 2010
Location: Global
Posts: 18,083
Quote:
Originally Posted by robwod View Post
It's not that big of a deal. Just login to the server and do a simple find and replace. The basic syntax is:

Code:
grep -rl "oldstring" . |xargs sed -i -e 's/oldstring/newstring/'
And example might be:
Code:
grep -rl "http://affiliatelink.com/track/affiliatecode/" . |xargs sed -i -e 's/http:\/\/affiliatelink\.com\/track\/affiliatecode\//https:\/\/affiliatelink\.com\/track\/affiliatecode\/'
I just did that quickly so I may have missed an escaped character. You simply need to use the first example, and then escape any special characters, including periods and slashes.
can't do that in cPanel or WHM
Barry-xlovecam is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote