简体   繁体   中英

Wordpress root directory issue

I had a site setup on a test domain and hosting. I then moved it to its actual domain and hosting account, and made all the changed needed for this to be a success.

I now have an issue of the media upload not working. The strange thing is that the error makes reference to the old root directory.

 /home/wwwOLD/public_html/wp-content/uploads/image1.tmp because No such file or directory in /home/wwwNEW/public_html/wp-admin/includes/file.php on line 178

Is there any reason why it would make reference to that old home directory, as I cannot see it in the database anywhere, or in any configs.

If you transferred the files rather than starting over from scratch, the configuration file was maintained which contains the location files should be uploaded to.

You should reinstall wordpress from scratch after making a backup of your database.

I've encountered that many times before in the past when moving wp sites. This is how I fixed them:

Go to your wp-admin / settings / media and update the field Store uploads in this folder

Either put blank there or put wp-content/uploads

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM