I've moved one of my domains from one host to another. In the old host this domain used to serve as the primary domain and placed at the root of wordpress multi-site install. Now, on the new host, this domain is just another subdomain, also as part of wordpress multi-site install. Also, its now placed in a dedicated subfolder.

The problem I'm having is that in some pages where I have images, not all are showing. Images where the link is showing as /domainName/wp-content/uploads/... show fine, but links using /domainName/files/... are not showing.

I've tried exporting the DB and searching for entries containing "files" but there are none. All links are in the format of wp-content/uploads. Yet, when visiting the site, I still get some images with the wrong path. Perhaps the site auto translates some of the paths to the files equivalent? I've also tried searching for a solution by changing rules in the .htaccess file but nothing helped so far.


This finally did the trick for me:

RewriteRule ^files/(.*)$ http://domain_name/wp-content/uploads/$1 [L,R=301]

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.